{{#theFunction.theArg}} Show this if theFunction("theArg") is not false #259

Closed
tobych opened this Issue Sep 19, 2012 · 1 comment

Projects

None yet

2 participants

@tobych

I'm working on getting Django's "Waffle" feature switches into mustache.

So far my template looks like:

{{#switch_is_active.show_save_filter}}
   <button id="save_filter" type="button">Save</button>
{{/switch_is_active.show_save_filter}}

Which is great. What I want though is to have this in the context:

switch_is_active: function(name) { return waffle.switch_is_active(name); }

Is that reasonable? Would this conflict with anything else?

@dasilvacontin
Collaborator

I'll close this issue due to inactivity. If it's still relevant, leave a comment and I'll reopen it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment