Skip to content

Create a vinyl object of a Modernizr JavaScript file

License

Notifications You must be signed in to change notification settings

shinnn/vinyl-modernizr

Repository files navigation

vinyl-modernizr

npm version Build Status Coverage Status

Create a vinyl object of a Modernizr JavaScript file

const vinylModernizr = require('vinyl-modernizr');

const file = vinylModernizr();
file.path; //=> '/Users/you/current/working/directory/modernizr.js'
file.contents.pipe(process.stdout); // prints '/*!\n * modernizr v3.6.0\n * Build http://modernizr.com/download? ...'

Installation

Use npm.

npm install vinyl-modernizr

API

const vinylModernizr = require('vinyl-modernizr');

vinylModernizr([options])

options: Object
Return: Vinyl

It returns a Vinyl object that contains modernizr-stream as its contents property.

Options

All options are passed to modernizr-stream and Vinyl constructor. Note that path option defaults to modernizr.js right under the current directory.

vinylModernizr().relative; //=> 'modernizr.js'

License

Copyright (c) 2016 - 2019 Shinnosuke Watanabe

Licensed under the MIT License.

About

Create a vinyl object of a Modernizr JavaScript file

Resources

License

Stars

Watchers

Forks

Packages

No packages published