aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Wagoner2014-02-10 00:17:08 -0800
committerCaitlin Potter2014-02-10 19:35:22 -0500
commita68624444afcb9e3796b1a751cf3817cafd20240 (patch)
tree241f842c1d4fa97489707dd8d23dd7134318a274
parent945fc1a4bca1a0856fc909f1d1b8d60d4a5e59bb (diff)
downloadangular.js-a68624444afcb9e3796b1a751cf3817cafd20240.tar.bz2
docs(ngSubmit): ngSubmit also works with the `data-action`/`x-action` attributes
The documentation states only the "action" attribute triggers this, which is incorrect. When using the attribute "data-action" (as for AJAX control, attempting to bypass the "action" attribute but still make it obvious what its for), Angular thinks this is also classified as "action" and continues with the page submission. Closes #6196
-rw-r--r--src/ng/directive/ngEventDirs.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ng/directive/ngEventDirs.js b/src/ng/directive/ngEventDirs.js
index f63d3ca1..45b2d404 100644
--- a/src/ng/directive/ngEventDirs.js
+++ b/src/ng/directive/ngEventDirs.js
@@ -298,8 +298,8 @@ forEach(
* Enables binding angular expressions to onsubmit events.
*
* Additionally it prevents the default action (which for form means sending the request to the
- * server and reloading the current page) **but only if the form does not contain an `action`
- * attribute**.
+ * server and reloading the current page), but only if the form does not contain `action`,
+ * `data-action`, or `x-action` attributes.
*
* @element form
* @priority 0