Socket
Book a DemoInstallSign in
Socket

duplexbufferstream

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

duplexbufferstream

A simple implementation of Stream.Duplex spec in Node.js

Source
npmnpm
Version
0.0.1
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

=== DuplexBufferStream

A simple implementation of Stream.Duplex spec in Node.js.

=== Example

===== tee.js:

` var DuplexBufferStream = require('duplexbufferstream'); var fs = require('fs');

var tee = new DuplexBufferStream(); process.stdin.pipe(tee).pipe(process.stdout);

var teeout = process.argv.length > 2 ? fs.createWriteStream(process.argv[2]) : process.stderr; tee.on('data', function(chunk) { teeout.write(chunk); }); `

=== Execution

$ echo "hello world" | node tee.js tee.output.log; cat tee.output.log hello world hello world $

Keywords

['stream'

FAQs

Package last updated on 24 Feb 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