co-from-stream

0.0.0 • Public • Published

co-from-stream

Create a co generator stream from a node stream.

Usage

var co = require('co');
var fs = require('fs');
var fromStream = require('co-from-stream');
 
co(function*(){
  var read = fromStream(fs.createReadStream('index.js'));
  
  var data;
  while (data = yield read()) console.log(data.toString());
})();

API

fromStream(stream)

Create a co generator stream from stream.

Installation

$ npm install co-from-stream

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.0
    217,274
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.0
    217,274

Package Sidebar

Install

npm i co-from-stream

Weekly Downloads

23,233

Version

0.0.0

License

MIT

Last publish

Collaborators

  • juliangruber