这里是我链入的JS
<script src="//mozilla.github.io/pdf.js/build/pdf.js"></script> <script> let pdfjsLib = window['pdfjs-dist/build/pdf']; pdfjsLib.GlobalWorkerOptions.workerSrc = '//mozilla.github.io/pdf.js/build/pdf.worker.js'; </script>
官方列子,https://mozilla.github.io/pdf.js/web/viewer.html
看它的例子 pagechanging 是如何挂载上去的
1.4m articles
1.4m replys
5 comments
57.0k users