#Puppeeter with cloudflare workers

3 messages · Page 1 of 1 (latest)

swift onyx
#

Hello! I recently saw this github repo : https://github.com/cloudflare/puppeteer

I have a SvelteKit project hosted on Cloudflare Pages and I would like to add an invoice system. I'm not very talented with PDFs, so I want to create PDF from HTML code. The only way I found was to use Puppeteer to render an html page and save it as PDF.

I did all my pdf tests in a separate project, and now that I feel more comfortable with puppeteer, I want to include it to my SvelteKit project.

I still have issues in understanding the difference between Workers and Pages, but from what I read Pages is meant for static websites, therefore there's no nodejs environment for puppeteer to run on. So my question is: Does cloudflare/puppeteer is meant to be use in workers ? If yes, can I include it in my sveltekit app and host the project in workers rather than pages ?

Have a nice day!

GitHub

Puppeteer Core fork that works with Cloudflare Browser Workers - cloudflare/puppeteer

hollow hawk
#
Cloudflare Docs

The Workers Browser Rendering API allows developers to programmatically control and interact with a headless browser instance and create automation flows for their applications and products. Once you configure the service, Workers Browser Rendering gives you access to a WebSocket endpoint that speaks the DevTools Protocol ↗. DevTools is what all...

swift onyx
#

Hello, I don't really understand... Are you telling me to use cloudflare browser rendering instead of puppeteer ?