T
TanStack3y ago
harsh-harlequin

Reset expanded rows on data changed

I'm trying to enable resetting expanded rows when data provided to table options has changed. I have manual pagination, and just update the data prop with items from current page. I tried setting autoResetExpanded to true which is actually it's default value, but it didn't work.
1 Reply
harsh-harlequin
harsh-harlequinOP3y ago
One way to do that is useEffect(() => { table.resetExpanded(); }, [data]); but I would like to use it in main table component which doesn't have data passed to it, only table

Did you find this page helpful?