dgzwba
Last Updated: February 25, 2016
·
17.18K
· kamilwysocki
Coderwall

How to set up a LESS build in Sublime Text

What's the point?

Switching software while developing an app or website may be frustrating if you do small changes and test them. Why then not incorporate a LESS plugin for your environment? Actually, there's a LESS-build package for Sublime Text, but it doesn't work properly for the newest LESS syntax (i.e. for the Bootstrap files). How to overcome this issue?

Install LESS

This can be done using Node Packaged Modules. Go to your command line and type:
npm install -g less
Simple as that.

Install Sublime Text package

Open Sublime Text, press Ctrl+Shift+P, select Package Control: Install Package. Then find Less2Css package and press enter.

You should now have this plugin installed. To use it, simply open your main .less file and resave it. A new file with the same name but with .css extension should appear in your LESS folder.

HTML/CSS/JS Prettify problems

If you use HTML/CSS/JS Prettify plugin, you may actually notice that your LESS files don't compile properly. This is caused by the prettify-on-save option. To turn it off press Alt+Shift+H and then o. Change line:
"format_on_save": true
to:
"format_on_save": false

Say Thanks
Respond

3 Responses
Add your response

14015
49e049f73ecf58ecfb150634a9097bbf

What's the date on this article???

over 1 year ago ·
15020
615a797afdf93c242e2b86221b9d02e6

What's the date on this comment?

over 1 year ago ·
21516
None

top of the page says: on Sep 16, 2013

over 1 year ago ·