daaain / Handlebars

Fullest Handlebars.js templating support for Sublime Text 2 / 3. Also drives syntax colouring on Github and in Visual Studio Code. Install from: https://packagecontrol.io/packages/Handlebars.
MIT License
301 stars 48 forks source link

Escaping of mustaches ignored #106

Open nknapp opened 4 years ago

nknapp commented 4 years ago

In Handlebars, a backslash can be used to prevent a mustache from being evaluated. Such a mustache is essentially text.

\{{no-expression}} {{expression}}

\{{{no-expression}}} {{expression}}

\{{#no}} block \{{/no}} {{expression}}

\{{\{{no}}}} block \{{\{{/no}}}} {{expression}}

see jsfiddle demonstrating the usage

I noticed that at least in GitHub markdown, the escaped mustaches are displayed just like regular expressions.

I came across this behavior when I made a similar pull request for highlight.js, it has not urgency for me. I just wanted to report it.