Launch Week Day 5: Introducing Reachability for PHP.Learn More
Socket
Book a DemoSign in
Socket

dev-null

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

dev-null

/dev/null for node streams

latest
Source
npmnpm
Version
0.1.1
Version published
Weekly downloads
955K
5.45%
Maintainers
1
Weekly downloads
 
Created
Source

dev-null build status

/dev/null for node streams

Use it whenever you need to interrupt stream flow for instance if you want to log the state of a stream instead of its output.

// without devnull
var numbers = require('../test/fixtures/number-readable')

numbers({ to: 2 })
  .on('data', function (d) { console.log(d.toString()) });
// => 
// 0
// 1
// 2
// piping into devnull
var devnull = require('dev-null');
var numbers = require('../test/fixtures/number-readable');

numbers({ to: 2 })
  .pipe(devnull())
  .on('data', function (d) { console.log(d.toString()) });

// => (no output)

Installation

npm install dev-null

License

MIT

Keywords

streams

FAQs

Package last updated on 10 Sep 2013

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