Edit on
<div></div>
<script id="tpl" type="text/x-handlebars-template">
	<p>Tags: {{listArray tags}}</p>
</script>
Handlebars.registerHelper('listArray', function(arr) {
    var out = [];	
    for (var i = 0, l = arr.length; i < l; i++) {
        out.push(arr[i]);
    }
    return out.join(', ');
});

$(function() {
	var data = {
		tags:[
			'javascript',
			'css',
			'handlebars'			
		]
	}

	var template = Handlebars.compile($('#tpl').html());
	$('div').append(
		template(data)
	);
});


Rerun