Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 3c12d36

Browse files
dmvtbtford
authored andcommitted
docs(select): add object comparison warning
1 parent fd6bac7 commit 3c12d36

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/ng/directive/select.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,11 @@ var ngOptionsMinErr = minErr('ngOptions');
1919
* represented by the selected option will be bound to the model identified by the `ngModel`
2020
* directive.
2121
*
22+
* <div class="alert alert-warning">
23+
* **Note:** `ngModel` compares by reference, not value. This is important when binding to an
24+
* array of objects. See an example {@link http://jsfiddle.net/qWzTb/ in this jsfiddle}.
25+
* </div>
26+
*
2227
* Optionally, a single hard-coded `<option>` element, with the value set to an empty string, can
2328
* be nested into the `<select>` element. This element will then represent the `null` or "not selected"
2429
* option. See example below for demonstration.

0 commit comments

Comments
 (0)