Live.js – The Key To CSS And JS Auto-Refreshing

Tags: , , , , , , , , , , , .

Posted 3 years ago

HR

 Live.js - The Key To CSS And JS Auto-Refreshing	Live.js, a JavaScript file, is an interesting tool created by Martin Kool. With this script, you can not only automatically check for modifications to your CSS and JavaScript files, but you can refresh them too.

With this tool, you can access the text editor on one part of your screen, and a web browser on the other. Whenever changes are saved in the editor, it reflects the updates in your browser immediately. This definitely helps in speeding up development time for users.

Though many text editors offer HTML previews, they work only for plain.html pages. But with the Live.js for WordPress plugin, it works on any webpage, including a working WordPress theme.

Live.js for WordPress Plugin

Once you download the plugin, rename the folder to “pbd-livejs” after you unzip it. You can also view it on Github.

The Live.js plugin automatically adds Live.js to your theme. It will do so when you’re working locally, and logged in. Just remember not to use this script on a live site.

Created for development purposes, the plugin keeps the script out of your theme code. It’s not required that the plugin to be present in the files on your server.

Live.js also supports detecting HTML changes, which has been disabled by the author. When enabled, it “flashes” in your webpage since it loads every second or two.

– Ady Sachdeva

HR

Leave a Reply