If any PHPStorm users want better syntax coloring for Antlers I figured out a better way.
-
Install Handlebars/Mustache plugin and enable the checkbox for “Open HTML files as Handlebars/Mustache” under Languages & Frameworks > JavaScript > Templates. Not perfect but much, much better!
-
This makes it even better. Disable Inspection and Syntax for Handlebars by click on Hector icon and changing the Highlighting Level for Handlebars to "None". Now no inspection errors!
-
Enjoy Statamic Antlers inside .html files in PHPStorm.
Unfortunately, your solution caused problems with automatic formatting for me. So I have found a slightly different solution.
In the settings under
Editor > File Types
I added the pattern*.antlers.html
to Twig and adjusted the syntax underPHP > Twig
.