Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit f302146

Browse files
authored
docs(forms): ngSubmit is an output property of NgForm directive (#3056)
incorporates and closes PR #3040
1 parent 9e02edd commit f302146

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

public/docs/ts/latest/guide/forms.jade

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -575,8 +575,8 @@ figure.image-display
575575
trigger a form submit because of its type (`type="submit"`).
576576

577577
A "form submit" is useless at the moment.
578-
To make it useful, we'll update the `<form>` tag with another Angular directive, `NgSubmit`,
579-
and bind it to the `HeroFormComponent.submit()` method with an event binding
578+
To make it useful, bind the `NgForm` directive's `ngSubmit` event property (in the `<form>` tag)
579+
to the `HeroFormComponent.submit()` method:
580580
+makeExample('forms/ts/app/hero-form.component.html', 'ngSubmit')(format=".")
581581

582582
:marked
@@ -671,7 +671,7 @@ figure.image-display
671671

672672
- An Angular HTML form template.
673673
- A form component class with a `Component` decorator.
674-
- The `ngSubmit` directive for handling the form submission.
674+
- Handling form submission by binding to the `NgForm.ngSubmit` event property.
675675
- Template reference variables such as `#heroForm`, `#name` and `#power`.
676676
- The `[(ngModel)]` syntax and a `name` attribute for two-way data binding, validation and change tracking.
677677
- The reference variable’s `valid` property on input controls to check if a control is valid and show/hide error messages.

0 commit comments

Comments
 (0)