k-yle / pdf-to-img

📃📸 Converts PDFs to images in nodejs
https://npm.im/pdf-to-img
MIT License
84 stars 22 forks source link

Can I convert to JPG and save to filesystem in Node? #213

Closed Konglomneshued closed 1 year ago

Konglomneshued commented 1 year ago

It's not really clear how to use the document returned from the pdf function call. It's not mentioned what type of image is created either.

ve3 commented 1 year ago

I agree to see simple example without jest-image-snapshot.

For example

for await (const page of await pdf("example.pdf")) {
    // what to do with `page`?
}