After the latest release of EmberJS v1.9.0
I am trying to move from Handlebars to HTMLbars. What I am finding very challenging is lack of documentation.
I am trying to implement very simple helpers.
For example take this handlebars helpers:
HTML
<div id="main"></div>
<script type="text/x-handlebars" data-template-name="index">
{{logIt test}}
<h1>{{test}}</h1>
</script>
JS
App = Ember.Application.create({
rootElement: '#main'
});
App.IndexRoute = Ember.Route.extend({
setupController: function(controller){
controller.set('test', 'mytest');
}
});
Ember.Handlebars.registerHelper("logIt", function(something) {
console.log(something);
});
Js Fiddle: http://jsfiddle.net/sisir/p463q2L8/
How do I convert it to htmlbars?