Package Exports
- reads
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (reads) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
reads
Transform all of your inputs to a Readable stream. Wrap all the things! It currently transforms:
- Strings, assumes they are file paths and returns
fs.createReadableStream - Buffers, transformed to a new "Buffered" Readable stream.
- Stream, just returns all the things.
npm install --save readsUsage
A single function is exposed which accepts a string, buffer or stream as
first argument and Stream options as a second argument. It always returns
a ReadableStream as result:
'use strict';
var reads = require('reads')
, stream;
stream = reads('/path/toa/file.js');
stream = reads(new Buffer('foo bar'));License
MIT