How to trigger Angular 2 input validation manually?
I found this to be much better
this.myForm.markAllAsTouched();
If you have template-driven form you can access form throw ViewChild decorator:
@ViewChild('myForm') public form: NgForm;
then, validate one field or the whole form group using method mentioned above:
this.form.controls.myControl.updateValueAndValidity();
You can update the validity of a formControl
form.controls['myControl'].updateValueAndValidity();