Well those are not simples if/else
statements, those ^
inside the {{}}
are called inverted sections
An inverted section begins with a caret (hat) and ends with a slash.
That is {{^person}} begins a "person" inverted section while
{{/person}} ends it.
While sections can be used to render text one or more times based on
the value of the key, inverted sections may render text once based on
the inverse value of the key. That is, they will be rendered if the
key doesn't exist, is false, or is an empty list.
And there is not compatibility issues using mustache
with handlebars 2.0
, make sure the hash look like this.
{
"repo": [] //or :false //or well it dosnt exists
}
Also you may wanna take a look into this proposal to change some features of mustache