Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Scrape titles from Reddit with node.js and node.io
require('node.io').scrape(function() {
this.getHtml('http://www.reddit.com/', function(err, $) {
var stories = [];
$('.entry .title').each(function(title) {
stories.push(title.text);
});
this.emit(stories);
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.