Regarding the Master Detail feature of MUI; when exporting to CSV from a Data Grid while implementing Master Detail the CSV export functionality stops working (understandably). Technically it works but only exports the first row (in my case). I looked around for a disable functionality of the master detail like there is for disableRowGrouping prop for groups but was not able to find one. Does this functionality exist and if not, do you have any suggestions on how I can turn on and off the Master Detail prop?
I did try conditionally adding the master detail feature to the DataGridPro component using state and a ternary statement like {!!someState ? getDetailPanelContent={({ row }) => <div>Row ID: {row.id}</div>}: false} however was not able to do so. I'm not sure if you can have conditional component props. Is this when a spread operator is used? If so, maybe someone can give an example of how to implement these two together?