To achieve this you can use Laravel Mix
- Ensure that Node.js and NPM are installed: run
node -v
andnpm -v
. - Install Laravel Mix
npm install
. - Open webpack.mix.js and add
mix.browserSync('127.0.0.1:8000');
. - Run
php artisan serve
. - And the
npm run watch
.
its stuck at [Browsersync] Reloading Browsers... . It downloaded so many files (500+) 100mb just for this, and still didnt work :)