aboutsummaryrefslogtreecommitdiffstats
path: root/src/ng/directive/form.js
diff options
context:
space:
mode:
authorBlaise Kal2013-11-25 16:13:41 +0100
committerPete Bacon Darwin2013-11-27 23:06:19 +0000
commit6f40c88f47c08eddba1e44b15fae2e844d15852b (patch)
tree38f68e8765034db3ad7465976d19408b64fd499a /src/ng/directive/form.js
parent68dd621082b6ccd347cf61e6b9f89025f4fe92dc (diff)
downloadangular.js-6f40c88f47c08eddba1e44b15fae2e844d15852b.tar.bz2
docs(form): provide a list of Angular's built-in validation tokens
As requested by a top-rated Disqus comment: http://docs.angularjs.org/api/ng.directive:form.FormController#comment-655325797 Closes #5121
Diffstat (limited to 'src/ng/directive/form.js')
-rw-r--r--src/ng/directive/form.js17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/ng/directive/form.js b/src/ng/directive/form.js
index 6f1f587e..0cd70844 100644
--- a/src/ng/directive/form.js
+++ b/src/ng/directive/form.js
@@ -21,9 +21,22 @@ var nullFormCtrl = {
* @property {Object} $error Is an object hash, containing references to all invalid controls or
* forms, where:
*
- * - keys are validation tokens (error names) — such as `required`, `url` or `email`,
- * - values are arrays of controls or forms that are invalid with given error.
+ * - keys are validation tokens (error names),
+ * - values are arrays of controls or forms that are invalid for given error name.
*
+ *
+ * Built-in validation tokens:
+ *
+ * - `email`
+ * - `max`
+ * - `maxlength`
+ * - `min`
+ * - `minlength`
+ * - `number`
+ * - `pattern`
+ * - `required`
+ * - `url`
+ *
* @description
* `FormController` keeps track of all its controls and nested forms as well as state of them,
* such as being valid/invalid or dirty/pristine.