Skip to content

Instantly share code, notes, and snippets.

@RohitRox
Created April 24, 2015 20:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save RohitRox/c88402de46e7347eb176 to your computer and use it in GitHub Desktop.
Save RohitRox/c88402de46e7347eb176 to your computer and use it in GitHub Desktop.
Highlight :javascript and :css block in haml in Sublime Text
// Sublime 3, comes installed with Rails package. This also provide "Ruby Haml". If you press ctrl + alt + p and type haml you will probably see two Set Syntax: Ruby Haml.
// The best solution for me was also install ApplySyntax and in it's user settings add the following:
// Put your custom syntax rules here:
"syntaxes": [
{
// This rule could be incorporated into the next one, but I prefer to be
// more explicit rather than less
"name": "Haml/Syntaxes/Ruby Haml",
"extensions": ["haml"],
"rules": [
{"file_name": ".*\\.haml$"}
]
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment