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

assemble-streams

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

assemble-streams - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

15

index.js

@@ -10,5 +10,7 @@ /*!

var handle = require('assemble-handle');
var through = require('through2');
var src = require('src-stream');
module.exports = function fn(app) {
var utils = require('./utils');

@@ -31,4 +33,3 @@ /**

app.mixin('toStream', function (name, filterFn) {
var stream = utils.through.obj();
var src = utils.srcStream;
var stream = through.obj();
stream.setMaxListeners(0);

@@ -57,9 +58,11 @@

});
return src(stream);
return src(stream).pipe(handle(this, 'onStream'));
});
if (app.isApp) return fn;
if (app.isApp) {
return fn;
}
};
function filter(key, view, fn) {

@@ -66,0 +69,0 @@ if (typeof fn === 'function') {

28

package.json
{
"name": "assemble-streams",
"description": "Assemble plugin that adds convenience methods for working with streams, like `toStream`, which pushes a view collection into a vinyl stream.",
"version": "0.3.0",
"description": "Assemble pipeline plugin for pushing a view collection into a vinyl stream.",
"version": "0.3.1",
"homepage": "https://github.com/jonschlinkert/assemble-streams",

@@ -13,4 +13,3 @@ "author": "Jon Schlinkert (https://github.com/jonschlinkert)",

"files": [
"index.js",
"utils.js"
"index.js"
],

@@ -25,3 +24,3 @@ "main": "index.js",

"dependencies": {
"lazy-cache": "^0.2.4",
"assemble-handle": "^0.1.0",
"src-stream": "^0.1.1",

@@ -31,4 +30,5 @@ "through2": "^2.0.0"

"devDependencies": {
"mocha": "*",
"templates": "^0.5.0"
"assemble-core": "^0.8.1",
"gulp-format-md": "^0.1.5",
"mocha": "*"
},

@@ -48,4 +48,16 @@ "keywords": [

]
}
},
"layout": "default",
"plugins": [
"gulp-format-md"
],
"reflinks": [
"base",
"update",
"generate",
"assemble",
"verb",
"templates"
]
}
}

@@ -1,16 +0,17 @@

# assemble-streams [![NPM version](https://badge.fury.io/js/assemble-streams.svg)](http://badge.fury.io/js/assemble-streams)
# assemble-streams [![NPM version](https://img.shields.io/npm/v/assemble-streams.svg)](https://www.npmjs.com/package/assemble-streams) [![Build Status](https://img.shields.io/travis/jonschlinkert/assemble-streams.svg)](https://travis-ci.org/jonschlinkert/assemble-streams)
> Assemble plugin that adds convenience methods for working with streams, like `toStream`, which pushes a view collection into a vinyl stream.
> Assemble pipeline plugin for pushing a view collection into a vinyl stream.
## Install
- [Usage](#usage)
- [Related projects](#related-projects)
- [Running tests](#running-tests)
- [Contributing](#contributing)
- [Author](#author)
- [License](#license)
Install with [npm](https://www.npmjs.com/)
_(TOC generated by [verb](https://github.com/verbose/verb) using [markdown-toc](https://github.com/jonschlinkert/markdown-toc))_
```sh
$ npm i assemble-streams --save
```
## Usage
This plugin can be used with [assemble][], [verb][] or any other application based on [templates][].
This plugin can be used with [assemble](http://assemble.io), [verb](https://github.com/verbose/verb) or any other application based on [templates](https://github.com/jonschlinkert/templates).

@@ -33,26 +34,6 @@ ```js

## API
### [.toStream](index.js#L29)
Push a view collection into a vinyl stream.
**Params**
* `collection` **{String}**: Name of the collection to push into the stream.
* **{Function}**: Optionally pass a filter function to use for filtering views.
* `returns` **{Stream}**
**Example**
```js
app.toStream('posts', function(file) {
return file.path !== 'index.hbs';
})
```
## Related projects
* [assemble](https://www.npmjs.com/package/assemble): Static site generator for Grunt.js, Yeoman and Node.js. Used by Zurb Foundation, Zurb Ink, H5BP/Effeckt,… [more](https://www.npmjs.com/package/assemble) | [homepage](http://assemble.io)
* [assemble-loader](https://www.npmjs.com/package/assemble-loader): Assemble plugin (0.6+) for loading globs of views onto custom view collections. Also works with… [more](https://www.npmjs.com/package/assemble-loader) | [homepage](https://github.com/jonschlinkert/assemble-loader)
* [assemble](https://www.npmjs.com/package/assemble): Assemble is a powerful, extendable and easy to use static site generator for node.js. Used… [more](https://www.npmjs.com/package/assemble) | [homepage](https://github.com/assemble/assemble)
* [assemble-loader](https://www.npmjs.com/package/assemble-loader): Assemble plugin (^0.6.0) for loading globs of views onto custom view collections. Also works with… [more](https://www.npmjs.com/package/assemble-loader) | [homepage](https://github.com/jonschlinkert/assemble-loader)
* [assemble-render-file](https://www.npmjs.com/package/assemble-render-file): Assemble plugin for rendering views in a vinyl pipeline. | [homepage](https://github.com/jonschlinkert/assemble-render-file)

@@ -76,8 +57,8 @@

+ [github/jonschlinkert](https://github.com/jonschlinkert)
+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
* [github/jonschlinkert](https://github.com/jonschlinkert)
* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
## License
Copyright © 2015 Jon Schlinkert
Copyright © 2016 [Jon Schlinkert](https://github.com/jonschlinkert)
Released under the MIT license.

@@ -87,2 +68,2 @@

_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on October 16, 2015._
_This file was generated by [verb](https://github.com/verbose/verb) on January 12, 2016._

Sorry, the diff of this file is not supported yet

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