Created
February 9, 2017 14:41
-
-
Save matthieu-D/db6ff036b85fbf51cf76a3d8665902d6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form [formGroup]="userForm" (ngSubmit)="onFormSubmitted(userForm)"> | |
<label> | |
<span>Name</span> | |
<input type="text" formControlName="name" placeholder="Name" required> | |
</label> | |
<div> | |
<label> | |
<span>Email</span> | |
<input type="email" formControlName="email" placeholder="Email" required> | |
</label> | |
</div> | |
<div formGroupName="address"> | |
<label> | |
<span>Country</span> | |
<input type="text" formControlName="country" placeholder="Country" required> | |
</label> | |
<div> | |
<label> | |
<span>City</span> | |
<input type="text" formControlName="city" placeholder="City" required> | |
</label> | |
</div> | |
</div> | |
<input type="submit" [disabled]="userForm.invalid"> | |
</form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment