angular putting validation on fields using validators code example
Example: formgroup check if valid
form: FormGroup;
onSubmit(){
//checks if form is valid
if( this.form.valid){
//more code here
}
}
form: FormGroup;
onSubmit(){
//checks if form is valid
if( this.form.valid){
//more code here
}
}