view-context
v0.1.0
Published
vinyl-view plugin that overwrites the `context` method on `view` to create the context used for rendering.
Downloads
12
Readme
view-context
vinyl-view plugin that overwrites the context
method on view
to create the context used for rendering.
Install
Install with npm:
$ npm install view-context --save
Usage
var context = require('view-context');
var View = require('vinyl-view');
View.use(context);
var view = new View('foo.hbs', {contents: new Buffer('My name is <%= name %>')});
var ctx = view.context({name: 'Bob'});
Contributing
This document was generated by [verb-readme-generator][] (a verb generator), please don't edit directly. Any changes to the readme must be made in .verb.md. See Building Docs.
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue. Or visit the [verb-readme-generator][] project to submit bug reports or pull requests for the readme layout template.
Building docs
Generate readme and API documentation with verb:
$ npm install -g verb verb-readme-generator && verb
Running tests
Install dev dependencies:
$ npm install -d && npm test
Author
Jon Schlinkert
License
Copyright © 2016, Jon Schlinkert. Released under the MIT license.
This file was generated by verb, v0.9.0, on June 08, 2016.