Skip to content

A hot loader for LESS, primarily intended for use with Electron

License

Notifications You must be signed in to change notification settings

squelch-irc/less-hot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

less-hot

A hot loader for LESS, primarily intended for use with Electron.

It compiles the LESS file, registers a watcher on the file, and returns a <style> element. Whenever the file is changed, the contents of that element will be updated.

Install

With npm do:

npm install less-hot

Example

var LessHotLoader = require('less-hot');
var lessLoader = new LessLoader();
document.querySelector('head').appendChild(lessLoader('test.less'));

Options

You can pass in an optional object to specify the cache directory for the less files. It will use a temporary directory by default.

var lessLoader = new LessLoader({cacheDir: '/path/to/dir/'});

About

A hot loader for LESS, primarily intended for use with Electron

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published