Latest Threat ResearchGlassWorm Loader Hits Open VSX via Developer Account Compromise.Details
Socket
Book a DemoInstallSign in
Socket

parallel-multistream

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

parallel-multistream

Parallel version of multistream

Source
npmnpm
Version
1.0.0
Version published
Weekly downloads
518
24.82%
Maintainers
1
Weekly downloads
 
Created
Source

parallel-multistream

Parallel version of multistream

npm install parallel-multistream

Usage

var parallel = require('parallel-multistream')

var stream = parallel([stream1, stream2, stream3])

stream.on('data', function(data) {
  // 1st: data will be from stream1
  // 2nd: data will be from stream2
  // 3rd: data will be from stream3
  // 4th: data will be from stream1
  // ...
})

stream.on('end', function() {
  // all streams have ended
})

Use stream.destroy() to all sub-streams and emit close.

If you want to add an additional stream you can call stream.add(substream).

License

MIT

FAQs

Package last updated on 18 Nov 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts