gulp-pure-cjs
v0.1.4
Published
Gulp plugin for Pure CommonJS builder
Downloads
16
Maintainers
Readme
gulp-pure-cjs
Getting Started
Install the module with:
npm install gulp-pure-cjs --save-dev
Add a task to your
Gulpfile.js
:
var pure = require('gulp-pure-cjs');
gulp.task('build', function() {
return gulp.src('./lib/index.js')
.pipe(pure({
exports: 'my-exported-module'
}))
.pipe(gulp.dest('dist'));
});
Beware!
pure-cjs
always re-read files from disk, so if you load other plugin in pipeline that
changes file content, this changes will be lost!
Options
The options object you use to call the plugin is passed to pure-cjs transform method with some change:
dryRun
is always set to true, in order to disable pure-cjs output file saveinput
is overwritten with filename received from gulp pipeline
For documentation on all other options available, see pure-cjs repo
Other stuff
- documentation - maybe I will add documentation if you ask it. Open an issue for this.
- support - open an issue here.
License
MIT © 2014, Andrea Parodi