angular reactive for check if field is valid code example
Example 1: formgroup check if valid
form: FormGroup;
onSubmit(){
//checks if form is valid
if( this.form.valid){
//more code here
}
}
Example 2: angular number validation
ng-pattern="re"