I am trying to use the automatically generated uischema through only the schema.
Using some simple schema as an example below, the input field for ‘name’ can be rendered, but below that the long description object just shows ‘No applicable renderer found.’
const renderers = [
...vanillaRenderers
// here you can add custom renderers
];
//under data()
renderers: Object.freeze(renderers)
Am I doing something wrong? Should I be using a custom renderer? I know I can probably build a uischema manually to create the form properly, but I want to avoid that if possible
the problem is that we don’t offer an object renderer at the moment, see also here. The ui schema generator just generates a Control for each property including description. The rendering then “fails” as there is no renderer handling the type: "object" schema.
To solve this you can implement your own object renderer which should be rather straightforward. You can basically copy the GroupRenderer, connect it with the useJsonFormsControlWithDetail composition (therefore also use control instead of layout to refer to the computed props) and use findUiSchema to find or generate the sub ui schema, like in the React Material object renderer.
Edit: We now also offer an object renderer, see here.
so since renderer do not support object, if I don’t create a custom one, but instead specify the uischema dynamically (i.e. parsing and storing properties found in schema manually, then create a function to push each properties as the ‘scope’ into the elements array within uischema)
I assume that will also do the job the same? Is that correct?
Sadly no. Vuetify for Vue 3 is a complete rewrite and not compatible to Vue 2. So we probably need a complete new renderer set, i.e. @jsonforms/vue3-vuetify or @jsonforms/vue-vuetify for this.
Please create a new question instead of adding to an existing one.
There is no difference between custom renderers and the off-the-shelf renderers. So feel free to look through the code base. You might want to copy an existing one and modify it to your liking to get going (e.g. a password-string renderer). There is also a more detailed guide as part of the Vue readme, see here.