Dynamic Grid Creations

Dear All

Is there a way to create a grid and the related cells dynamically on load in the init function?

Best regards
Matthew Lucas

@matthew Unfortunately not. At time of writing, the only view components that can be dynamically created (i.e. from JS/TS) are the <sidebar /> and nav-drawer

Some “dynamic” UI requirements can be met using <object-repeat /> whilst others can be met by hardcoding a preset amount of UI components and then showing / hiding them based on the data that is passed to the view.
For example, you can have the semblance of an object table with a dynamic number of columns by hardcoding 20 columns in the XML and then only showing the ones that are actually required to render the data in question. Obviously this requires you to know what the upper limit of the dynamic nature of the data is going to be. And this same logic could theoretically be applied to grids and cells - but I realize your mileage may vary depending on the exact nature of your data and the UI requirements that you have.

Finally, when all else fails you can implement a custom UI component using the HTML iFrame

Hi Tielman

Awesome, thank you for the response.

We have been dabbling with the HTML component side for some of our more complex solutions for example a report creator which accesses our MYSQL database where users can create reports querying models and their related models as well as create custom filters and groupings etc, the challenge is always getting our components to render in line with / looking similar to those similar journey components, so that users believe the HTML component is apart of the app and not another page embedded in the app.

I will also have a look at to see if that will give us options for our other use cases.

Best regards
Matt