Browser not reloading on file event change
See original GitHub issueIssue details
Please provide issue details here. Browser not reloading on file event change, sometimes it will but in another session it does not reload
Steps to reproduce/test case
Running Browsersync v2.23.6 with Gulp & VVV local development, browser is not reloading after file has changed, the issue is intermittent, singular body tag exists.
Issue is odd as sometimes the reload works - then it will simply stop and I am not able to get it going even with a gulp task restart, browsersync sync and browser restart.
Please provide necessary steps for reproduction of this issue, or better the reduced test case (without any external dependencies).
Please specify which version of Browsersync, node and npm you’re running
- Browsersync [ 2.23.6 ]
- Node [ 8.9.0 ]
- Npm [ 5.5.1 ]
Affected platforms
- linux
- windows
- [x ] OS X
- freebsd
- solaris
- other (please specify which)
Browsersync use-case
- API
- Gulp
- Grunt
- CLI
If CLI, please paste the entire command below
{cli command here}
for all other use-cases, (gulp, grunt etc), please show us exactly how you’re using Browsersync
{Browsersync init code here}
> Executing task: node_modules/.bin/gulp sync <
[10:24:44] Using gulpfile ~/remote-dev/www/mysite/htdocs/wp-content/themes/mysitetheme/gulpfile.js
[10:24:44] Starting 'sync'...
[10:24:44] Finished 'sync' after 14 ms
[Browsersync] Proxying: mysite.test
[Browsersync] Access URLs:
-------------------------------------
Local: http://localhost:3000
External: http://192.168.0.11:3000
-------------------------------------
UI: http://localhost:3001
UI External: http://192.168.0.11:3001
-------------------------------------
[Browsersync] Watching files...
[Browsersync] File event [change] : style.css
Gulp task
// Fire up browserSync
gulp.task('sync', function() {
browserSync.init({
proxy: "mysite.test",
files: ["./*.css","*.php","css/*css","lib/*.php", "includes/*.php", "includes-child/*.php", "includes-child/woocommerce/*.php", "includes-child/woocommerce/*.css"],
xip: false
});
});
Have tried… Rrestarting all the things, Check for duplicate instances of body tag Changed proxy value to localhost:3000 Resync’ing browsers from UI xip values both true and false
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (2 by maintainers)
Top GitHub Comments
Here’s the solution that worked for me:
injectChanges
istrue
by default: https://www.browsersync.io/docs/options#option-injectChanges@uaibo This worked for me, thanks !