parseChapters method

Future<List<EpubChapter>> parseChapters()

Implementation

Future<List<EpubChapter>> parseChapters() async {
  if (_chapters.isNotEmpty) return _chapters;

  checkEpubLoaded();

  final result = await webViewController!.evaluateJavascript(source: 'getChapters()');

  _chapters = parseChapterList(result);
  return _chapters;
}