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

Commit

Permalink
docs(input): update $parsers NgModelController doc
Browse files Browse the repository at this point in the history
Make it clear that the result of the $parsers pipeline is what goes to the model value.

Closes #5708
  • Loading branch information
gillius authored and pkozlowski-opensource committed Feb 28, 2014
1 parent 6b5baad commit 0c8a88b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ng/directive/input.js
Original file line number Diff line number Diff line change
Expand Up @@ -878,8 +878,9 @@ var VALID_CLASS = 'ng-valid',
* @property {*} $modelValue The value in the model, that the control is bound to.
* @property {Array.<Function>} $parsers Array of functions to execute, as a pipeline, whenever
the control reads value from the DOM. Each function is called, in turn, passing the value
through to the next. Used to sanitize / convert the value as well as validation.
For validation, the parsers should update the validity state using
through to the next. The last return value is used to populate the model.
Used to sanitize / convert the value as well as validation. For validation,
the parsers should update the validity state using
{@link ngModel.NgModelController#$setValidity $setValidity()},
and return `undefined` for invalid values.
Expand Down

0 comments on commit 0c8a88b

Please sign in to comment.