Live data from Hacker News

The new browser-based puppeteer REPL, and how we built it

docs.browserless.io

1–10 of 32 posts

Re: The new browser-based puppeteer REPL, and how we built it

#3
I've used Puppeteer extensively and its the most unstable tool that I've come across in recent years. Its full of race conditions and the waitForSomething functions will sometimes work, sometimes not.

It's usable, but it's very aggravating and uncomfortable to use.

Re: The new browser-based puppeteer REPL, and how we built it

#4
post #2

Hey, Joel here, mostly responsible for this tool. Happy to answer questions — one thing not well covered is getting puppeteer to run in the browser, especially a webworker. Can talk more about it if there’s interest!

How to set up my own mirror/instance of chrome.browserless.io? Is there a step-by-step guide for it? The git repo just mentions:

> The application is written in TypeScript, and produces a static asset in the static directory once built.

What should I do with said artifact? How to put it to use?

Re: The new browser-based puppeteer REPL, and how we built it

#5
post #2

Hey, Joel here, mostly responsible for this tool. Happy to answer questions — one thing not well covered is getting puppeteer to run in the browser, especially a webworker. Can talk more about it if there’s interest!

How to set up my own mirror/instance of chrome.browserless.io? Is there a step-by-step guide for it? The git repo just mentions: > The application is written in TypeScript, and produces a static asset in the static directory once built. What should I do with said artifact? How to put it to use?

You can actually install our docker image or use the npm module:

https://github.com/browserless/chrome/blob/5627f1ef041ec23f3...

Re: The new browser-based puppeteer REPL, and how we built it

#6
post #2

Hey, Joel here, mostly responsible for this tool. Happy to answer questions — one thing not well covered is getting puppeteer to run in the browser, especially a webworker. Can talk more about it if there’s interest!

could you share why you chose puppeteer over playwright? thanks!

Re: The new browser-based puppeteer REPL, and how we built it

#7
post #6
post #2

Hey, Joel here, mostly responsible for this tool. Happy to answer questions — one thing not well covered is getting puppeteer to run in the browser, especially a webworker. Can talk more about it if there’s interest!

could you share why you chose puppeteer over playwright? thanks!

Just familiarity with puppeteer, eventually this tool will support both. Puppeteer has less “moving parts” for now

Re: The new browser-based puppeteer REPL, and how we built it

#9
post #2

Hey, Joel here, mostly responsible for this tool. Happy to answer questions — one thing not well covered is getting puppeteer to run in the browser, especially a webworker. Can talk more about it if there’s interest!

This is magical and cool.

As a web dev generalist, I can usually understand how most things work under the hood.

But playing with chrome.browserless.io breaks that. You're streaming the web page in a element, but how can I highlight text? When I load a youtube video page are you literally proxying the video through your infra, through pixels to my browser?

Who dictates what IP the headless chrome is assigned to? Do you have a lot of IPs? I noticed on some pages I'd get the CloudFlare captcha which makes sense if browserless has to cycle through a limited set of IPs where other people have been using it to scrape another cloudflare page.

Re: The new browser-based puppeteer REPL, and how we built it

#10
post #3

I've used Puppeteer extensively and its the most unstable tool that I've come across in recent years. Its full of race conditions and the waitForSomething functions will sometimes work, sometimes not. It's usable, but it's very aggravating and uncomfortable to use.

Surprising to me -- I used puppeteer last year for a couple of projects and found it to be extremely pleasant to use -- almost fun even! You can just pick it up and most of the api seemed relatively straightforward. I found it a little annoying to get things like reliable window placement (yes I do want the chrome incognito to be in this exact place and size everytime).

But it seemed very solid overall and especially so compared to the selenium monstrosities I remember trying to fight (and giving up) some years prior ...

Post reply on HN