Custom column subRow for different data type? (Nested Trees, but with mixed subRow data) #136
-
|
If I follow the "Expanding Sub Rows (Tree Data)" example here: https://www.material-react-table.com/docs/guides/expanding-sub-rows (Thanks) it states: "NOTE: This feature is for expanding rows of the same data type. If you want to add expansion of more data for the same row, check out the Detail Panel Feature Guide." But the Detail Panel Feature is a formatted output. Is it possible to do another SubRow without the same data type? Reason is, my data is from GraphQL. Thanks Kevin, great work. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
No, that's what Detail Panel is for. It can be in any kind of UI within the Detail panel that you want to make though. The fact that you data comes from graphql should not matter. If you really want to join your data together into similar columns, you just need to parse it in a useMemo or something before passing it to the table. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks KevinVandy for your hard work. .. trying to close this issue |
Beta Was this translation helpful? Give feedback.
No, that's what Detail Panel is for. It can be in any kind of UI within the Detail panel that you want to make though.
The fact that you data comes from graphql should not matter. If you really want to join your data together into similar columns, you just need to parse it in a useMemo or something before passing it to the table.