gulp-dir2module
v0.0.5
Published
Creates a single browserify/commonjs module that includes all files in a directory.
Downloads
2
Maintainers
Readme
gulp-dir2module v0.0.2
Information
Usage
var dir2module = require('gulp-dir2module');
gulp.task('dir2module', function() {
gulp.src('js/controllers/*.js')
.pipe(dir2module('controllers.js'))
.pipe(gulp.dest('js/controllers'))
});
This will create a file in the js/controllers directory called controllers.js that exports a map with each js file (excluding itself).