Answer the question
In order to leave comments, you need to log in
How to make minified js in the same folder using gulp-uglifyjs ?
For some time now, the question has not left me how to make minified js files side by side,
gulp.task('uglify', function() {
gulp.src('js/**/*.js')
.pipe(uglify())
.pipe(gulp.dest('dest'))
});
Answer the question
In order to leave comments, you need to log in
Write your plugin, with blackjack, etc. which will take all the files from the stream and do aggregation (you can use gulp-uglify as a basis). uglifyjs concatenates all files by default, otherwise there is not much point in such optimization.
Well, as an option - expand the glob and get a list of files, form an array of streams and apply uglify to each. Essentially the same as with the option with the plugin but without the plugin.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question