Search code examples
hamlphpstormfile-type

PhpStorm shows Haml file like plain text (transcompilation works, but not the syntax highlighting)


The syntax highlighting for my haml files in PhpStorm does not work, and the icon is just the icon for plain text. (It should be a red icon with an h, similar to the icon for the scss file.)

wrong icon and no syntax highlighting

The transcompilation works only if File type in the watcher is set to Text files. If I choose HAML files, it tells me that there are "No such files in scope".

No such files in scope

Any ideas, why PhpStorm recognizes the scss file, but not the haml file?


Solution

  • First of all -- make sure that HAML support plugin is installed and enabled (whould be by default).

    If plugin is good:

    • Settings | File Types
    • Text files entry
    • Find and remove offending pattern (quite possible will be background-clip.haml or similar)