DEV Community

loading...

Discussion on: Parametrized Validators in Dynamic Forms

Collapse
matheo profile image
Mateo Tibaquirá Author

Yes, every DynControl is able to have its Validators but in the Config type structure:

{
  options: { validators: [...someCustomValidators] },
  controls: [ ..fieldsConfigs ]
}
Enter fullscreen mode Exit fullscreen mode

I'm improving the typing of the Config right now to detect inline ValidatorFn in case we don't want to provide them via id and just want to build a fast prototype :)

Forem Open with the Forem app