1.0.0 • Published 7 years ago

bytes-stream v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

Bytes Stream

Bytes Stream - output range bytes from readable stream

$ npm install bytes-stream

Example

Read range bytes from readable stream fs.createReadStream(), start from 10 and end on 20 (not included).

const bytes = require('bytes-stream'),fs=require('fs');

fs.createReadStream('/dir/file.txt').// readable stream
pipe(new bytes([10, 20])).// range start from 10 and end on 20
on('data', d => console.log('data', d.toString()));// output data

Bytes Stream is licensed under the MIT license. See the included LICENSE file for more details.