Specify a OneWay Binding in HandleBars - Ember

Posted by Miguel Madero on Stack Overflow See other posts from Stack Overflow or by Miguel Madero
Published on 2013-10-17T18:13:38Z Indexed on 2013/10/19 15:54 UTC
Read the original article Hit count: 129

Filed under:

Is there a way to Specify a OneWay Binding in HandleBars? bind-attr always calls Ember.bind, which always create a two way binding. This seems to be the case for elements that don't even change:

<img {{bind-attr class=":class-name-to-always-apply"}}>

But even in cases where the element could change, we might have reasons to update it manually (e.g. performance or we don't want to change it on textChanged, but do it manually)

© Stack Overflow or respective owner

Related posts about ember.js