Readibility

Extract the Readable Content from an HTML Document

README

Readability.js


A standalone version of the readability library used for Firefox Reader View.

Installation


Readability is available on npm:

  1. ``` sh
  2. npm install @mozilla/readability
  3. ```

You can then require() it, or for web-based projects, load the Readability.js script from your webpage.

Basic usage


To parse a document, you must create a new Readability object from a DOM document object, and then call the [parse()](#parse) method. Here's an example:

  1. ``` js
  2. var article = new Readability(document).parse();
  3. ```

If you use Readability in a web browser, you will likely be able to use a `document` reference from elsewhere (e.g. fetched via XMLHttpRequest, in a same-origin `