What are form control directives (form directives)?
Form control directives are special Angular directives that bind form elements to the FormControl and FormGroup system, allowing the form's state to be tracked and controlled.
There are two main groups:
1. For template-driven forms:
ngModel- binds a field to a component variable.ngForm- creates a form object and manages it.ngModelGroup- groups fields within a form.
2. For reactive forms:
formControl- binds an element to a specificFormControl.formGroup- binds a container (usually<form>) to aFormGroup.formArrayName/formGroupName- bind nested structures.
Their job is to connect HTML elements to the form model, so that Angular can track the value, validation, and status of each field.
Short Answer
Interview readyPremium
A concise answer to help you respond confidently on this topic during an interview.