Skip to content

Instantly share code, notes, and snippets.

@zdwolfe
Created August 3, 2013 20:06
Show Gist options
  • Save zdwolfe/6147808 to your computer and use it in GitHub Desktop.
Save zdwolfe/6147808 to your computer and use it in GitHub Desktop.
script
var fs = require('fs');
var readability = require('readability');
var html = fs.readFileSync('test.html', 'utf-8');
// This is an very early example. The API is subject to change.
readability.parse(html, 'http://www.cnn.com/2013/08/01/politics/congress-work-time/index.html?hpt=hp_t1', function(result) {
console.log(JSON.stringify(result, null, 4));
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment