reagent

Ryan 2022-11-18T20:31:30.357339Z

Hope this is the right place: I have a react component (PrimeReact DataTable) that takes some XML for a react property, e.g. data-header = <ColumnGroup><Row><Column name=“test” field=“field”></Row></ColumnGroup> … how do I correctly set that on the cljs side? It looks like the #js literal wants a map or vector.. the documentation for the component is here: https://www.primefaces.org/primereact/datatable/colgroup/ and specifically I’m looking to set the headerGroup property, dynamically ultimately, but my first pass can be static. Thanks for help!

2022-11-23T09:59:56.008629Z

FYI you can remove the double quote for number values.

Ryan 2022-11-18T21:07:26.717769Z

So far this has worked:

:headerColumnGroup (reagent.core/as-element [:> ColumnGroup
                             [:> Row
                              [:> Column {:header "Provider" :colSpan "1"}]
                              [:> Column {:header "Office" :colSpan "1"}]
                              [:> Column {:header "Monday, October 10,2020" :colSpan "9"}]
                              ]])
.. it’s a start.