Multiple files changed = multiple reloads. Global debounce?
See original GitHub issueMy gulp workflow sometimes will yield multiple html files (e.g. I change a Jade partial and 3 dependent files are regenerated) within 1-2 seconds. This cause BS to reload as many times as the number of files, sometimes actually missing the last one (incidentally exactly the one I have open in the browser).
Is there a way to debounce these refreshes? Ideally it should happen either:
_.debounce(refresh, 1000)
, a second after the last file changes, or_.debounce(refresh, 1000, {leading:true})
, as soon as the first file changes and a second after the last file changes
Issue Analytics
- State:
- Created 9 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
Debouncing with multiple hooks - javascript - Stack Overflow
When adjusted to my code, the implementation looks like this: const debounce = (fn, delay) => { let timerId; return (... args) =>...
Read more >Debouncing watcher tasks with Gulp 4 · Issue #1304 - GitHub
Debounce the gulp.watch handler that restarts Koa. This needs to debounce across multiple files (e.g. if Webpack writes a.js, b.js, ...
Read more >Use dynamic configuration using push refresh in a .NET Core ...
In this tutorial, you learn how to dynamically update the configuration data for .NET Core apps using push refresh.
Read more >Throttle & Debounce - devsign
Debounce is always the most recent value when it fires. Throttle feels faster and more responsive. Debounce feels more accurate. Here's a ...
Read more >Troubleshooting 3650/3850 reloads by stack manager ... - Cisco
From there, ask for those very specific reports from those given switches so the customer does not upload several files. The crashinfo directory ......
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
2.6.0
has reload-delay & reload-debounce available on the CLIThis is a sample project that simulates the behavior with gulp while launching BS from CLI: DOWNLOAD
Keep in mind that I wouldn’t be able to solve the issue it like I did in my second post (i.e. within gulp itself)
Demo. Notice how the timestamp changes 3 times