buffer-to-vinyl
Create a vinyl file or stream from a buffer
Last updated 10 years ago by kevva .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install buffer-to-vinyl 
SYNC missed versions from official npm registry.

buffer-to-vinyl Build Status

Create a vinyl file or stream from a buffer

Install

$ npm install --save buffer-to-vinyl

Usage

var bufferToVinyl = require('buffer-to-vinyl');
var fs = require('fs');

bufferToVinyl.file(fs.readFileSync('foo.jpg', null));
bufferToVinyl.stream(fs.readFileSync('foo.jpg', null));

API

.file(buf, [name])

Creates a vinyl file.

.stream(buf, [name])

Creates a object stream.

License

MIT © Kevin Mårtensson

Current Tags

  • 1.1.0                                ...           latest (9 years ago)

3 Versions

  • 1.1.0                                ...           9 years ago
  • 1.0.1                                ...           9 years ago
  • 1.0.0                                ...           10 years ago
Maintainers (1)
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (4)
Dev Dependencies (2)
Dependents (2)

© 2010 - cnpmjs.org x YWFE | Home | YWFE