parser for hacker news comments


Parses the insanely shitty html of hacker news comments into json

var hn = require('hacker-news-parser');
request("https://news.ycombinator.com/item?id=4992617", function(errres) {
  if(err) throw err;
  var content = hn.parse(res.body);

parses the html of a hacker news post

returns {comments: [comment], more: moreLink} note: moreLink will be null if there is no 'more' link at the bottom

represents a single comment

raw html body of the comment

utc date of the comment

url to the comment

url to the next page of comments