handlebars.js
handlebars.js copied to clipboard
Strict mode errors on unless block with nested property
When strict: true
is added Handlebars errors on the use of a missing nested property in an unless block helper.
var myObject = {};
{{#unless myObject}}
{{/unless}}
-> no error
{{#unless myObject.prop.prop}}
{{/unless}}
-> error "prop doesn't exist"
As described in this issue strict mode shouldn't be enforced on helpers and conditional block. The point of a conditional block is to handle (non-)existence of properties.