stream-stream
Advanced tools
Comparing version 1.1.0 to 1.1.1
{ | ||
"name": "stream-stream", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "A stream of streams in order to concatenates the contents of several streams", | ||
@@ -24,3 +24,4 @@ "main": "index.js", | ||
"devDependencies": { | ||
"nodeunit": "0.7.x" | ||
"nodeunit": "0.7.x", | ||
"stream-sink": "1.x.x" | ||
}, | ||
@@ -27,0 +28,0 @@ "author": "Florent Jaby <florent.jaby@gmail.com>", |
@@ -1,2 +0,2 @@ | ||
[![Build Status](https://travis-ci.org/Floby/node-stream-stream.png)](https://travis-ci.org/Floby/node-stream-stream) | ||
[![Build Status](https://travis-ci.org/Floby/node-stream-stream.png?branch=master)](https://travis-ci.org/Floby/node-stream-stream) | ||
@@ -34,2 +34,23 @@ node-stream-stream | ||
You can also add a separator between the contents of each stream by specifying a `separator` | ||
field in the options. | ||
```javascript | ||
var mystream = new ss({ | ||
separator: '\n', | ||
// if separator is a function, it will get called | ||
// everytime the stream needs to insert a separator | ||
separator: function(cb) { | ||
cb('\n'); | ||
}, | ||
separator: function(cb) { | ||
cb(someReadableStream) | ||
} | ||
}); | ||
``` | ||
It is also possible to `pipe()` to this stream from a readable stream in objectMode. | ||
Test | ||
@@ -40,3 +61,10 @@ ---- | ||
Contributing | ||
------------ | ||
Anyone is welcome to submit issues and pull requests | ||
thanks to [vanthome](https://github.com/vanthome) | ||
License | ||
@@ -43,0 +71,0 @@ ------- |
var SS = require('../'); | ||
var Sink = require('./sink'); | ||
var sink = require('stream-sink'); | ||
@@ -8,3 +8,3 @@ | ||
var finished = false; | ||
ss.pipe(Sink()).on('data', function(data) { | ||
ss.pipe(sink()).on('data', function(data) { | ||
test.equal(data, '', "There should be no data"); | ||
@@ -11,0 +11,0 @@ finished = true; |
var stream = require('stream'); | ||
var SS = require('../'); | ||
var sink = require('./sink'); | ||
var sink = require('stream-sink'); | ||
@@ -5,0 +5,0 @@ exports.testMultiSync = function(test) { |
var stream = require('stream'); | ||
var SS = require('../'); | ||
var sink = require('./sink'); | ||
var sink = require('stream-sink'); | ||
@@ -5,0 +5,0 @@ exports.testOneStream = function(test) { |
var util = require('util'); | ||
var stream = require('stream'); | ||
var SS = require('../'); | ||
var sink = require('./sink'); | ||
var sink = require('stream-sink'); | ||
@@ -6,0 +6,0 @@ function EmitStream (array) { |
var util = require('util'); | ||
var stream = require('stream'); | ||
var SS = require('../'); | ||
var sink = require('./sink'); | ||
var sink = require('stream-sink'); | ||
@@ -6,0 +6,0 @@ function EmitStream (array) { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
14767
80
2
11
388