Live Edit in PhpStorm for Laravel projects

Viewed 1153

I like to use Live Edit feature, however, it seems to me it only works with regular .html files, however, none of the known to me ways work with Laravel .blade.php files. Google didn't answer. Is there really no way to do so?

1 Answers

For Laravel projects, you can use BrowserSync to automatically refresh websites when you make changes to your template files. Support for BrowserSync comes out of the box with Laravel Mix. To use this feature, all you have to do is go to your webpack.mix.js file and add the mix.browserSync() function call. If you're using Laravel Valet or something similar to get pretty URLs, you can pass in a URL as an argument to proxy.

mix.browserSync();

// OR

mix.browserSync('my-domain.test');

Documentation: Compiling Assets (Mix)

Related