"dependentRequired" not working?

Hi all!

I have problems to get “dependentRequired” working.

Is this a “known issue” (to be implemented) or am I doing something wrong?

see:

Hi @cornelos,

There are two sides to this:

  • We use the default AJV for validating which does not support JSON Schema draft-2019-09, see here. To workaround this problem you can instantiate an AJV version which supports this draft and hand it over to JSON Forms via the ajv prop.
  • JSON Forms does not yet have a customization for dependentRequired errors, so even when handing over an AJV instance producing these errors, they are currently not correctly mapped to the respective control and therefore do not show up in the UI.

We would definitely like to see the latter functionality in JSON Forms, so if if you (or anyone else) would like to contribute this, then feel free to do so :wink:

1 Like