Skip to content

Latest commit

 

History

History
10 lines (5 loc) · 553 Bytes

angular_mim.md

File metadata and controls

10 lines (5 loc) · 553 Bytes

Angular Mistakes I Made

Watch out one-way binding when bind to object

It just copies the references, so any change you made from child is actually changing the parent.

From Angular Doc and Github Issue:

one-way binding does not copy the value from the parent to the isolate scope, it simply sets the same value. That means if your bound value is an object, changes to its properties in the isolated scope will be reflected in the parent scope (because both reference the same object).