Ask a Question
Back to All

Handlebar helper in detail view?

I added a Handlebar helper:

Handlebars.registerHelper('if_eq', function(a, b, block) {
if(a == b) return block.fn(this);

which I called in the item.hbs:
{{#if_eq btw "geen"}}0% btw{{/if_eq}}

This works fine in the item view, but doesn't work in detail view. Probably because the template.hbs isn't called?
I tried adding {{registerscript "handlebars-helpers.js"}} but that doesn't work...

How can I get this to work?