wycats/handlebars.js — pull request #212 by rjack (2012-03-31 23:23:01+00:00)
Title: add separator support in `each`

Hello,

with this commit, `each` accepts a `sep` hash argument that is used as separator.

For example:

var hb = require('handlebars');
var render = hb.compile('{{#each items sep=","}}{{this}}{{/each}}');
var data = {
items: [ "foo", "bar", "baz" ]
};

console.log(render(data));

outputs

foo,bar,baz

I need this for a project, maybe it could come handy for others too.

Cheers,
Giacomo