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

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

Comments

Projects
None yet
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

This comment has been minimized.

Show comment
Hide comment
@krisselden

krisselden May 31, 2012

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().

Member

krisselden commented May 31, 2012

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

This comment has been minimized.

Show comment
Hide comment

@krisselden krisselden closed this May 31, 2012

@hennk

This comment has been minimized.

Show comment
Hide comment
@hennk

hennk May 31, 2012

Ah, good to know. Thanks!

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