Answers for "formgroup control has error"

1

angular formgroup validate manually

//Validate all the form group
this.form.updateValueAndValidity();

//Validate only one form control
this.form.controls['formControlName'].updateValueAndValidity();
Posted by: Guest on May-10-2021
0

formgroup is not property of form angular

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { AppComponent }  from './app.component';

@NgModule({
    imports: [
        BrowserModule,
        FormsModule,
        ReactiveFormsModule
    ],
    declarations: [
        AppComponent
    ],
    bootstrap: [AppComponent]
})

export class AppModule { }
Posted by: Guest on September-13-2021

Code answers related to "TypeScript"

Browse Popular Code Answers by Language