batch-write-stream
Write stream that batches all writes done in the same tick.
Install
$ npm install batch-write-stream --save
Use
Require
var BatchWriteStream = ;
Create
var stream = ;
Or, with options:
var options = highWaterMark: 100 // default maxConcurrentBatches: 1 // default; var stream = ;
Implement _writeBatch
stream { // batch is an array // call cb when done}
Map
You can map each value before it is written:
stream { return ;};
License
MIT