How to pass blob to the viewer.js in PDF.js and how to display pdf in separate window
问题 I have loaded the pdf in canvas but unable to pass it to viewer.js in PDF.js. Examples only show how to pass to canvas not to viewer.js and i want to load the pdf in different window 回答1: PDF.js comes with a viewer. You can embed an iframe/frame in your page, or open a new window. The url will be the same for both: pdfjs/web/viewer.html?file=URL_TO_YOU_PDF You can also pass binary data: // atob() is used to convert base64 encoded PDF to binary-like data. // (See also https://developer.mozilla