2 ms·
There are great non-blocking IO examples out there which are pretty easy to find (look at any database, file system, or networking library), but I think jsdom i
by catch23 16y ago
There are great non-blocking IO examples out there which are pretty easy to find (look at any database, file system, or networking library), but I think jsdom is a rather unique library that is hard to find in other languages:
https://github.com/tmpvar/jsdom https://github.com/tmpvar/jsdom
jsdom implements DOM level 2 so you could actually mimic the javascript run in webpages (ie it would actually properly evaluate document.write() embedded in script tags). Web page scraping libraries in other languages won't have this feature easily because other languages will need to include a javascript interpreter along with their DOM emulator. I believe there's a java library out there that makes use of rhino to do this (htmlunit) but it took them quite some time to get there (several years). Most of the hard work in jsdom was implemented in a few months.
- deleted 16y ago[deleted]