co-node-read

0.0.2 • Public • Published

co-node-read

co wrapper for node-read

Usage

read(html [, options])

Where

  • html url or html code.
  • options is an optional options object

Example

var co = require('co');

var read = require('./index');

co(function * () {

  var article = yield read('http://news.163.com/14/0905/18/A5DA5S6N00014SEH.html');

  // Main Article.
  console.log(article.content);

  // Title
  console.log(article.title);

  // HTML 
  console.log(article.html);

  // DOM
  console.log(article.dom);

})();

LISENCE

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.2
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.2
    1

Package Sidebar

Install

npm i co-node-read

Weekly Downloads

0

Version

0.0.2

License

MIT

Last publish

Collaborators

  • littlehaker