Reputation: 11
I want to create custom component for input text but I don't know how can I bind validation of each input field to custom component. Is there any way to set errors of each field as array of objects like below
[errors]="[
{ type: 'required', message: 'REQUIRED'},
{ type: 'minlength', message: 'MINLENGTH=3' }
]"
Upvotes: 1
Views: 60