Skip to content

Angular Reactive Forms

fonlow edited this page Jan 9, 2024 · 3 revisions

"As of Angular 14-16, reactive forms are strictly typed by default.", however, constructing typed FormGroup in TypeScript codes is still a manual process. OpenApiClientGen can generate client API codes that generate FormGroups which include validation codes according to some data constraints of each data types

Mappings

Validations

Constraints NG Validators
Required required
minLength minLength
maxLength maxLength
minimum min
maximum max
RegularExpression pattern

Examples of Generated Codes

Clone this wiki locally