Interleave multiple input streams into a single stream
npm install interleave-stream

> Interleave multiple input streams into a single stream
Will emit chunks from input streams in order, e.g. [s1chunk1, s2chunk1, s3chunk1, s1chunk2, s2chunk2, etc..]. Use split or block-stream2 in order to control chunks from input streams.
```
npm install -S interleave-stream
`js
var interleave = require('interleave-stream')
var split = require('split2')
var s1 = split()
var s2 = split()
interleave([s1, s2]).pipe(process.stdout)
s1.end('1\n2\n3')
s2.end('A\nB\nC')
// outputs 1A2B3C to stdout`
`js`
var interleave = require('interleave-stream')
Where:
- streams is an array of readable streamsopts` is the same as the options for ReadableStream
-
Returns a ReadableStream that interleaves chunks from input streams in order.
For objectMode streams.
PRs accepted.
Small note: If editing the Readme, please conform to the standard-readme specification.
MIT © Gregor MacLennan