![]() ![]() Don't stop a process with Ctrl+C in the terminal.Close the current terminal and open a new terminal and run grunt watch.Grunt message: Fatal error: Port 35729 is already in use by another process Open your custom.css or less file for example then change something then save, here you'll see in grunt watch some new line appears tells that this file has been changed something like:Īnd look now your browser, the item that you just changed appeared and updated instantly without reloading the page, also without cleaning the cache or deploying the static-content, everything is done automatically.Check if the LiveReload browser extension icon is well activated, in firefox the icon comes green, in Chrome the small dot inside the circle becomes full black.If you create a new less file it won’t be exist in the theme, So you have to create a symlink using grunt commands.$ cp /usr/local/lib/node_modules/livereload/bin/livereload.js. usr/local/lib/node_modules/livereload/bin/ You can get the file path of livereload.js during the installation. ![]() Move the livereload.js to your Magento_root It is hardcoded value, remove it while moving the code to the production server. We use port 35729 because the LiveReload only connects to that port. livereload -v (will display the installed version)Īdd the bellow line inside tag in default.xml or default_head_blocks.xml of your current theme.Įxample: app/design/frontend/ /Magento_Theme/layout/default_head_blocks.xml:.Install LiveReload package and check it.Install live reload extension for Chrome/ Firefox.With the liveReload it's over all that, it is just enough to save the update and 'Hoop' magically the content that you have changed instantaneously appear without refreshing the browser and without cleaning the cache, deploying the static-content either but for the cache, you also need Grunt. when you change a CSS file or an image, the browser is updated instantly without reloading the page. As soon as you save a file, it is preprocessed as needed, and the browser is refreshed. LiveReload monitors changes in the file system. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |