Closed oyb81076 closed 8 years ago
` var newer = require("gulp-newer") ; var gulp = require("gulp") var source = require("vinyl-source-stream"); var buffer = require("vinyl-buffer"); gulp.task("lib", function(){ return browserify("lib.js").bundle() .pipe(source("lib-bundle.js")) .pipe(buffer()) .pipe(newer("./lib-bundle.js")) .pipe(gulp.dest(".")) }); // through events.js:141 // throw er; // Unhandled 'error' event
gulp.task("lib2", function(){ return browserify("lib.js").bundle() .pipe(source("lib-bundle.js")) .pipe(buffer()) .pipe(gulp.dest(".")) });//works well
`
Please see https://github.com/gulpjs/gulp/blob/master/docs/recipes/fast-browserify-builds-with-watchify.md for details on getting fast incremental builds with Browserify (using Watchify is the way to go).
` var newer = require("gulp-newer") ; var gulp = require("gulp") var source = require("vinyl-source-stream"); var buffer = require("vinyl-buffer"); gulp.task("lib", function(){ return browserify("lib.js").bundle() .pipe(source("lib-bundle.js")) .pipe(buffer()) .pipe(newer("./lib-bundle.js")) .pipe(gulp.dest(".")) }); // through events.js:141 // throw er; // Unhandled 'error' event
gulp.task("lib2", function(){ return browserify("lib.js").bundle() .pipe(source("lib-bundle.js")) .pipe(buffer()) .pipe(gulp.dest(".")) });//works well
`