XaminProject/handlebars.php — pull request #36 by cgray (2014-01-20 03:20:12+00:00)
Title: Add support for .length on arrays

This pull requests adds support for templates like

There are {{items.length}} items in your todo list

for data structured like

{
"items":[
"Get Milk",
"Get Eggs",
"Get Beer"
]
}

Current implementation sees length as an undefined property and yields

There are items in your todo list

Handlebars JS returns

There are 3 items in your todo list