zip together two streams into a single stream with aligned pairwise data
npm install tuple-streamzip together two streams into a single stream with aligned pairwise data


This is easy to understand with lines:
`` js
var split = require('split');
var through = require('through');
var tuple = require('../');
var a = split(), b = split();
tuple(a, b).pipe(through(function (pair) {
this.queue(pair[0] + ' | ' + pair[1] + '\n');
})).pipe(process.stdout);
a.end('one\ntwo\nhree\n4\nfive');
b.end('one\ntwo\nthree\nfour\n');
`
output:
``
one | one
two | two
hree | three
4 | four
five |
Here the split module chunks up its input by newlines, sending a separatetuple
chunk for each line. The module kicks in and aligns the events by ordera
such that the first event from is paired with the first event from b and
so on.
` js`
var tuple = require('tuple-stream')
Return a readable stream that zips together the data from readable streams ab
and into an array data chunk with [achunk,bchunk].
With npm do:
```
npm install tuple-stream
MIT