Mattias Alfborger
Mattias Alfborger

Reputation: 868

How do you add syntax highlighting for Less in Notepad++?

I want Notepad++ to treat my .less files just as my .css files and thereby get syntax highlighting for any .less files I open.

Upvotes: 54

Views: 34005

Answers (2)

kapex
kapex

Reputation: 30019

To get LESS syntax highlighting, you have to download and import a user defined language file. Here are some links to language files:

Installation instructions from the GitHub repository:

  • Download the less.xml file
  • Open Notepad++
  • Go to Language -> Define your language..., click on Import... and select the less.xml file you've downloaded
  • Close and restart Notepad++
  • Done

Another way to install language files is to copy them into a file in the Notepad++ installation directory.

Upvotes: 62

Fred K
Fred K

Reputation: 13910

Download from this page the XML file of the language to add (such as Less)

In Notepad++ open Language menu > Define your language... and Import the file

Upvotes: 4

Related Questions