I am trying to evaluate a string in if statement using JSON templates.
This works:
{.if true}
<h1>It is true</h1>
{.end}
However, this syntax breaks the page:
{.if "foo"=="bar"}
<h1>Not true</h1>
{.end}
How do I compare strings using JSON templates?
I don't think this is doable, and I'm sure you don't wanna harcode values like this especially on a template that defeats the purpose.
try: