Files
PDF.js/examples/node/pdf2png
Yu Cong 44db9807a1
Some checks failed
Types tests / Test (lts/*) (push) Has been cancelled
Lint / Lint (lts/*) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
CI / Test (20) (push) Has been cancelled
CI / Test (22) (push) Has been cancelled
CI / Test (24) (push) Has been cancelled
first commit
2025-10-03 22:20:19 +08:00
..
2025-10-03 22:20:19 +08:00
2025-10-03 22:20:19 +08:00

Overview

Example to demonstrate converting a PDF file to a PNG image using the PDF.js library.

Getting started

Install the dependencies and build the PDF.js library:

$ npm install
$ gulp dist-install

Run the example to convert the first page of a PDF file to a PNG image:

$ cd examples/node/pdf2png
$ node pdf2png.mjs