AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Alternative to livereload11/5/2022
The setup can be a little bit tricky, depending on the type of LiveReload you want to use, since the config.rb file needs to reside in the main directory of your project for the App, and in the SASS directory if you use the Sublime Text 2 plugin. The compiler is not only triggered if you save the main SCSS file, but also if you edit a partial (an included file). It’s the perfect companion for SASS, the favorite CSS preprocessor everybody seems to use. For the sake of completeness I also want to mention that it can be combined with the browser extension, although that doesn’t make much sense, since the script already takes care that LiveReload works in every environment.īut LiveReload has even more to offer. The script method works with the LiveReload app as well as Sublime Text 2 (or any other supported editor). Now if you change a file the differences also appear magically on your (mobile) device. #Alternative to livereload how toKeen to know how to do that? Find out the IP address of your computer and enter it – including the (web server) path to your project – into your device you want have the LiveReload behavior on. If you prefer the script method of LiveReload you have a big bonus: the live changes are also available on other devices apart from your developing machine – which, however, might again require a web server. But where there is shadow there is also light (or is it vice versa?). “Way easier than the hassle with web servers and browser extensions” you might think, but not every project allows to insert something else unneeded to every single page. Insert it right before the closing tag and you’re all set. If your web site is running on another server, you need to specify the IP address of your local computer instead. It’s much simpler to set up, but has the disadvantage that you need to insert a small script into every HTML (or PHP or whatever) page of your project (which the browser plugin handles for you at the first method). If all of that is much too complicated for you, there still remains the second way to use LiveReload which I promised above. What to type in at the Package Control command prompt. Now restart Sublime Text 2 once more and like at the native App you just need to enter the localhost URL from above into your browser, enable the LiveReload plugin by clicking on it and from now on every change of the files of your project are directly reflected in your browser without the need to reload. Then hit Enter, wait a few seconds to load, write “LiveReload”, select the appearing entry, hit “Enter” again and the plugin is installed. #Alternative to livereload installThe exact installation process can be found here.Īfter you have restarted the editor, hit CMD + Shift + P (CTRL + Shift + P for Windows) to open a Package Control prompt, type in “Install” and “Package Control: Install Package” should immediately be highlighted. #Alternative to livereload codeFirst you need to install the essential package manager Package Control, which just requires to enter some code into the console (“View > Show console” at the menubar of Sublime Text 2).
0 Comments
Read More
Leave a Reply. |