first of all thank you for this great solution that you provide as open source project!
I have a question about guidelines regarding performance when forms have lots of fields and many of them are dropdowns. Going from tab to tab is real pain for the user experience, it might take 10 seconds to transition the screens.
Thanks Alexandr for the answer.
I already developed custom renderer set but my observation is that if form has > 50 fields with some dependecies and effects taking place there is some delay in the initial render.
As far as I understand the performance of jsonforms/core is good enough, and place for optimization is in the components that render?
Hi @evgeni, from our experience rendering is usually not the issue. However as @alexandrsashin mentioned, we noticed performance problems with certain schemas in regards of ref resolving. These typically occur with recursive refs.
@evgeni Can you share your used JSON schema? If not can you reproduce the performance problem with a small example and share that one? Which renderer set are you using?
Hi @sdirix ,
first of all I am extremely grateful that you joined this conversation.
Here you can see two examples, Person and ScrollableLayout.
The Person example uses simpler schemas, while the ScrollableLayout has really advanced schemas.
@evgeni Thanks for providing the detailed example, that’s very helpful. On a first look I didn’t see any $ref in the schema, so it doesn’t look like a ref resolving issue. So it’s either the custom renderers or something I’m currently unaware of in JSON Forms, especially as you indicated that most of the time is spent in the JsonFormsDispatchRenderer.
@alexandrsashin What makes you think the enums pose the performance problem? On a first glance it seems to be worse to fetch them only once you want to render them as you’ll have to additionally wait for the fetch. Of course when all of them have to be fetched beforehand and the schema is only generated after all of them are fetched there might be a difference in first time to render, but I don’t think this is what’s happening here, or is it @evgeni ?
@evgeni I’ll have more time next week to look at this issue, I’ll let you know when I took a closer look.
Hi @sdirix ,
thank you for looking in this issue.
I have prepared code where enum values are prefetched in redux store and dropdowns get their values from the store.
Only value I can see in what @alexandrsashin is proposing is that there will be no validation done by AJV on the allowed value for the dropdown, because this way it is going to be just a “string” in the jsonschema description.
I looked a bit at the example but it’s hard to debug it properly with the deployed production build. A developer build would make the investigation easier