Laravel-mix: Reload for any file changes as like BrowserSync

Created on 12 Feb 2017  路  3Comments  路  Source: JeffreyWay/laravel-mix

Thanks a lot for making this. Currently page only refresh on JavaScript changes. Can we get a feature that refreshes page for css, php, blade file changes as like BrowserSync does. Thanks

Most helpful comment

Are you using Mix in a Laravel project, or something unrelated? If unrelated, you'll need to specify which file paths should be watched.

// https://browsersync.io/docs/options/
mix.browserSync({
    proxy: 'my-domain.dev',
    files: ['paths/here/**/*.php']
})

Otherwise, for Laravel projects, it should automatically watch all relevant directories.

All 3 comments

Are you using Mix in a Laravel project, or something unrelated? If unrelated, you'll need to specify which file paths should be watched.

// https://browsersync.io/docs/options/
mix.browserSync({
    proxy: 'my-domain.dev',
    files: ['paths/here/**/*.php']
})

Otherwise, for Laravel projects, it should automatically watch all relevant directories.

Could this be added to the documentation? I just stumbled into this issue myself.

Thanks @JeffreyWay that helped me out greatly! I have been banging my head against a wall until i found that.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pixieaka picture pixieaka  路  3Comments

rderimay picture rderimay  路  3Comments

rlewkowicz picture rlewkowicz  路  3Comments

amin101 picture amin101  路  3Comments

kpilard picture kpilard  路  3Comments