-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Two-way bindings to array members not updating when data edited in dom-repeat template (bug or feature?) #1821
Comments
Thanks so much for adding this, It has really really been doing my head in. I guess this is a bug since the workaround would be to serialise the object into an array of objects. How I'd love a solution for this! |
@bvhme Someone on SO found a workaround: http://stackoverflow.com/a/30760144/4220785 |
@vsimonian Yeah, saw that, it only works if you have an |
This demo points out two issues that have been separately reported:
Closing this, as we'll track the two issues separately |
Thanks for the pointers, @kevinpschaaf! I'll be keeping an eye on #1839 |
No worries. Will be on the lookout for the fix |
Thanks so much! |
Given some sort of input element within a
dom-repeat
template, if the element's value is bound to a member of the collection to which the repeating template is bound, the value of the collection's respective item will not update when the element has its value changed.For example:
The
iron-input
element bound directly tolabels.0
functions as expected. It both a) updates when the value oflabels[0]
is changed, and b) updates the value oflabels[0]
when its own value is changed.However, the
iron-input
elements inside of the template will not update the values of the array members when input is provided. They will update upon the array being mutated, though.Live demo at http://jsbin.com/xuhitowiji/1/edit?html,output
The text was updated successfully, but these errors were encountered: