This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
ngValue one way binding? #13984
Closed
Description
Hi.
I'm trying to use ng-value in an input box as a one way binding. But the thing is, when the model changes, the input box is not reflecting the new value. I'm debugging the ngValue directive and i can see that the watcher is triggered, under the hood the value is being set with setAttribute (using element.attr). That is setting the value of the attribute, but it is not changin the view.
I created this fiddler, and I see this strange behaviour. Just have a look at the value reflected in the view and the value in the console.debug. Is this normal behaviour? Can anyone explain this to me?
https://jsfiddle.net/upqeksf0/
This is in Chrome 46, I haven't checked other browsers.