Skip to content

Bindings declared in Mixins do not get applied when reopening instance #918

Closed
hennk opened this Issue May 31, 2012 · 3 comments

2 participants

@hennk
hennk commented May 31, 2012

With Ember 0.9.8.1, in http://jsfiddle.net/MUuf6/1/, when clicking the link to apply the mixin to the view, the myBinding property does not seem to be initialized as a binding, as can be seen when clicking on 'Click me' after clicking on 'Include mixin'.

But the binding does get applied correctly when doing the same with 0.9.7.1 in http://jsfiddle.net/WcaYn/1/

Is this an expected change between 0.9.8.1 and 0.9.7.1?

@krisselden
Ember.js member

Bindings have problems when applied to prototypes and reopen isn't designed for existing instances. It may have seemed to work before but it didn't without bugs. You should apply your mixin to the existing instance with apply().

@krisselden krisselden closed this May 31, 2012
@hennk
hennk commented May 31, 2012

Ah, good to know. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.