UNPKG

rx-form-mapper

Version:

Proper decorator-based transformation / serialization / deserialization of plain javascript classes to angular reactive forms

12 lines (11 loc) 519 B
import { Type } from '@angular/core'; import 'reflect-metadata'; import { RxValidator, RxAsyncValidator, UpdateOn } from '..'; export interface FormArrayOpts { validators?: RxValidator | RxValidator[]; asyncValidators?: RxAsyncValidator | RxAsyncValidator[]; updateOn?: UpdateOn; type: Type<any>; } export declare function FormArray(type: Type<any>): (target: Object, propertyName: string) => void; export declare function FormArray(opts: FormArrayOpts): (target: Object, propertyName: string) => void;