×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Text
Posted by: Nilesh Yadav
Added: Jun 14, 2017 7:27 PM
Views: 5
Tags: no tags
  1. <form #userForm.value="ngForm" (onSubmit)="onSubmit(userForm.value)">
  2.  
  3. <input name="name" ngModel>
  4. <!-- data binding start -->
  5. <input name="email" ([ngModel])="varname_of_component">
  6. <!-- data binding end -->
  7.  
  8. <div ngModelGroup="address">
  9. <input name="city" ngModel>
  10. <input name="postalcode" ngModel>
  11. </div>
  12. </form>