Can't properly screenshot Page with Javascript

I have setup a a Page on CloudFlare which accepts URL params to define a background image. The page also contains a threeJS scene. When I visit the page in the browser it renders fine. However, when I use the Browser Rendering as outlined here: https://developers.cloudflare.com/browser-rendering/get-started/browser-rendering-with-do/ it takes a screenshot of the Page without the background image (inserted by JS) and the threeJS scene. I tried using the waitForFunction() and waitForElement() but it times out.I also tried setting a 10sec delay between the page being opened and it being screenshot. However this doesn't help. I am doing this: page.on('console', (message) => { console.log(Browser Console: ${message.text()}); }); --- And get this: Browser Console: THREE.WebGLRenderer: Error creating WebGL context.
Deploy a Browser Rendering Worker with Durable Objects · Browser Re...
By following this guide, you will create a Worker that uses the Browser Rendering API along with Durable Objects to take screenshots from web pages …
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server