Open tiberiuichim opened 1 year ago
Hey @tiberiuichim can you explain the issue in some detail ?
The form validation is hardcoded. The only way to add new validators in a form is either by declaring a new widget or type and patching
widgetValidation
.
In an on-going non-Volto project, we are using react-jsonschema-form to render and validate forms, and it works pretty well. We took the idea of rendering JSONSchema based forms from Volto.
I know that Volto renders the forms using custom widgets, but perhaps using a library like this, can bring validators 'for free'.
I know that modifying Volto to use a library like this is a larger project than adding proper validator support, and may be even unachievable, but it may be interesting.
I just discussed with @sneridagh and one possible (even if limited) solution would be to move widgetValidation
to the configuration registry and allow people to register new validations (if needed).
The form validation is hardcoded. The only way to add new validators in a form is either by declaring a new widget or type and patching
widgetValidation
.