Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

stream-to-pull-stream

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stream-to-pull-stream

convert a stream1 or streams2 stream into a pull-stream

  • 1.6.8
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
19K
decreased by-57.49%
Maintainers
1
Weekly downloads
 
Created
Source

stream-to-pull-stream

Convert a classic-stream, or a new-stream into a pull-stream

example

var toPull = require('stream-to-pull-stream')
var pull = require('pull-stream')

pull(
  toPull.source(fs.createReadStream(__filename)),
  pull.map(function (e) { return e.toString().toUpperCase() }),
  toPull.sink(process.stdout, function (err) {
    if(err) throw err
    console.log('done')
  })
)

if the node steam is a duplex (i.e. net, ws) then use toPull.duplex(stream, cb?) duplex takes an optional callback in the same way that sink does.

License

MIT

FAQs

Package last updated on 07 Apr 2016

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc