Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Pseudosynchronous JavaScript.
http://horsemanjs.org/
The library runs PhantomJS. While there are many libraries that do this, I wanted a synchronous, chainable API. So I could do
var links = horseman.count('a'); if (count > 3) { horseman.open('http://www.google.com') } else { horseman.open('http://www.yahoo.com') }
Under the hood, using the library literally blocks. Which is a very, very un-javascript/Node thing to do, and introduces other weirdness, I know.
There are no comments on this comment yet.
http://horsemanjs.org/
The library runs PhantomJS. While there are many libraries that do this, I wanted a synchronous, chainable API. So I could do
var links = horseman.count('a'); if (count > 3) { horseman.open('http://www.google.com') } else { horseman.open('http://www.yahoo.com') }
Under the hood, using the library literally blocks. Which is a very, very un-javascript/Node thing to do, and introduces other weirdness, I know.