Gulp 4: increases compile time on each save
See original GitHub issueWhile gulp watch for changes, compile time increased with every save, even if the styles do not change much.
Running on Windows 7x64
, gulp v4
, gulp-sass v2.2.0
Gulp task to compile sass:
function compileSass() {
return gulp.src(srcDir + 'scss/app.scss')
.pipe(plugins.plumber({
errorHandler: onError
}))
// globbing CSS @import
.pipe(plugins.sassBulkImport())
.pipe(plugins.sass({
sourceMapContents: true,
sourceMapEmbed: true
}))
.pipe(gulp.dest(srcDir + 'css/'))
.pipe(browserSync.reload({stream: true}));
}
Issue Analytics
- State:
- Created 7 years ago
- Comments:11
Top Results From Across the Web
Gulp execution time gets increased with every run
When i'm starting gulp, everything is working great but with every run tasks execution time gets increased. I'm using :.
Read more >Gulp v4 - Sass and BrowserSync setup - YouTube
In this video I look at how we can setup a gulp build that will compile Sass for us, and automatically sync all...
Read more >How to Migrate to Gulp.js 4.0 - SitePoint
Learn how to migrate to Gulp.js 4.0 and update your 3.0 gulpfile.js configurations. Find out what you need to know about changes in...
Read more >5 Strategies to Reduce Frontend Build Time with CI/CD
So, In this article will take you through four different strategies to optimize the front-end build time with CI/CD.
Read more >Simplify Front-end JS and CSS Optimization With Gulp - Toptal
We will find that we now have two files with hashtags affixed to each of the filenames, and a manifest.json saved to public/build...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
+1
This problem occurs not only when compiling SASS. I watch it from Gulp 4 and when compiling Pug. (In a completely identical repository from Gulp 3, I do not observe such a problem.) Win10.
Apparently, the authors of the Gulp 4 are more comfortable not to get this problem 😦 https://github.com/gulpjs/gulp/issues/1748 This is the opensource, baby! )))
ps: the problem can be solved if you avoid using
**/
in thegulp.watch
. To write not**/*.scss
, and to specify more precisely:yourDirectory/*.scss
This solution is not convenient, but I have not found another yet.Has this been fixed? I feel like still experiencing this.