Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Binding failure in $init #278

Open
flongo opened this issue Sep 1, 2014 · 0 comments
Open

Binding failure in $init #278

flongo opened this issue Sep 1, 2014 · 0 comments
Labels

Comments

@flongo
Copy link
Collaborator

flongo commented Sep 1, 2014

When an attribute of a component is "2-way"-bound, the data model is not updated if the attribute is modified in the $init method of the component.

You can find an example here: http://plnkr.co/edit/KQFVQ8kC6GoKctYE38uD

On top of that, if the $refresh method is implemented in the controller and another attribute is changed inside of it, the update done in the $init is ignored: http://plnkr.co/edit/gARSz3kim7YNKQrMBkaH

This is probably due to the fact that the value for the index attribute is re-read from the data-model, which hasn't been updated before.

@flongo flongo added the bug label Sep 1, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant