initializePdfRenderer method
Initializes the PDF renderer instance in respective platform by loading the PDF from the specified path.
Implementation
@override
Future<String> initializePdfRenderer(
Uint8List documentBytes, String documentID) async {
Settings documentData = Settings()..data = documentBytes.toJS;
final documentLoader = PdfJs.getDocument(documentData);
final PdfJsDoc pdfJsDoc = await documentLoader.promise.toDart;
final int pagesCount = pdfJsDoc.numPages;
_documentRepo[documentID] = pdfJsDoc;
return pagesCount.toString();
}