Top "Angular2-forms" questions

An Angular form is a collection of data input controls.

password and confirm password field validation angular2 reactive forms

I need to check whether password and confirm password fields have same value using reactive form angular2. I did see …

angular angular2-forms
Angular2 reactive forms delete error

I´m trying to set a form control status to valid this.currencyForm.controls['currencyMaxSell'].setErrors({smallerThan: true}) now I …

angular angular2-forms
Angular2 - How to set `touched` property on form to true

I have a reactive form in my component and I want to set the touched property on every one of …

forms angular angular2-forms reactive-forms
Manually sanitize a string

I have an textarea where the user will type in some text. The text cannot be JavaScript or HTML etc. …

angular angular2-forms
Angular 2 Reactive Forms - Detect input change event on component

I would like to detect the value of change event to the input on form.component.ts. I would not …

angular2-forms
Set value of <mat-select> programmatically

I'm trying to set value of 2 fields <input matInput> abnd <mat-select> programatically. For text input everything …

angular angular2-forms angular-material2 angular5 angular-reactive-forms
How to set a form as pristine?

The form that represents entity state is being edited (turns dirty) The form is being submitted and entity state is …

angular angular2-forms
How to get name of input field from Angular2 FormControl object?

I have an Angular 2 application that uses the ReactiveForms module to manage a form that uses a custom validator. The …

angular typescript angular2-forms angular-forms
How to correctly import FormGroup in NgModule in Angular 2

I try to import FromGroup, FormBuilder and FormControl to my CustomModule: import { FormsModule, FormGroup } from '@angular/forms'; @NgModule({ imports: [ …

angular import angular2-forms ng-modules
mat-select required validation not working

I have the following code <form #createForm="ngForm"> <mat-form-field> <mat-select placeholder="Favorite food" matInput [ngModel] …

angular5 angular2-forms angular-material2 redux-form-validators