在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称:mozilla/pdf.js开源软件地址:https://github.com/mozilla/pdf.js开源编程语言:JavaScript 97.7%开源软件介绍:PDF.jsPDF.js is a Portable Document Format (PDF) viewer that is built with HTML5. PDF.js is community-driven and supported by Mozilla. Our goal is to create a general-purpose, web standards-based platform for parsing and rendering PDFs. ContributingPDF.js is an open source project and always looking for more contributors. To get involved, visit:
Feel free to stop by our Matrix room for questions or guidance. Getting StartedOnline demoPlease note that the "Modern browsers" version assumes native support for
features such as
Browser ExtensionsFirefoxPDF.js is built into version 19+ of Firefox. Chrome
Getting the CodeTo get a local copy of the current code, clone it using git:
Next, install Node.js via the official package or via nvm. You need to install the gulp package globally (see also gulp's getting started):
If everything worked out, install all dependencies for PDF.js:
Finally, you need to start a local web server as some browsers do not allow opening
PDF files using a
and then you can open: Please keep in mind that this requires a modern and fully up-to-date browser; refer to Building PDF.js for non-development usage of the PDF.js library. It is also possible to view all test PDF files on the right side by opening: Building PDF.jsIn order to bundle all
If you need to support older browsers, run:
This will generate Using PDF.js in a web applicationTo use PDF.js in a web application you can choose to use a pre-built version of the library
or to build it from source. We supply pre-built versions for usage with NPM and Bower under
the Including via a CDNPDF.js is hosted on several free CDNs:
LearningYou can play with the PDF.js API directly from your browser using the live demos below: More examples can be found in the examples folder. Some of them are using the pdfjs-dist package, which can be built and installed in this repo directory via For an introduction to the PDF.js code, check out the presentation by our contributor Julian Viereck: More learning resources can be found at: The API documentation can be found at: QuestionsCheck out our FAQs and get answers to common questions: Talk to us on Matrix: File an issue: Follow us on Twitter: @pdfjs |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论