logoalt Hacker News

andai • today at 2:25 AM • 0 replies • view on HN

Huh, very cool. Not quite interactive speed, but I guess it's meant for agents, so plenty fast for that?

(Also, lol at the "testimonials"!)

This reminded me, in uni I made a web scraper that ran fully in the browser.

Or it would have, if CORS didn't exist. I had to proxy it thru a 1 line PHP script so requests would be "to the same server". Sekurity achieved.

Of course, web scraping is recursive, so I thought, why not visualize that? So it would extract links from each loaded page, and then fetch those pages too. And then render those websites in nested divs under the original one, and so on. Web-ception!

Original code lost, but I recall it being like 30 LoC or something.

Edit: OK Recreated it from memory but without the recursive scraping bit. So it's just a "normal" browser-in-browser now (lol). Microscopic Python proxy included. https://pastebin.com/AMwCkZai