Expandable + Filterable Table: subRows empty after a filter was set
See original GitHub issueDescribe the bug (required)
A clear and concise description of what the bug is.
When using a table with the useFilters
and useExpand
plugins, the subRows
of a row with children is empty after setting a filter and clearing it again.
Provide an example via Codesandbox! (required) https://codesandbox.io/s/runtime-currying-odrn8?file=/src/App.js
Steps To Reproduce (required)
- Open the provided code sandbox
- expand the first row (optional), just to make sure there are subRows
- Filter the second column (Visits) to
29
- Remove the filter from the second column (Visits) again
- The first row doesn’t have
subRows
any longer
Expected behavior (Recommended) I would expect that I can see the original subrows of each row after removing all filters
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: MacOS Catalina 10.15.4
- Browser: Chrome
- Version: 81.0.4044.138
Issue Analytics
- State:
- Created 3 years ago
- Reactions:5
- Comments:7
Top Results From Across the Web
subRows empty after a filter was set · Issue #2309 · TanStack ...
When using a table with the useFilters and useExpand plugins, the subRows of a row with children is empty after setting a filter...
Read more >Filters | TanStack Table Docs
The ability for a column to be column filtered is determined by the following: The column was defined with a valid accessorKey /...
Read more >Filter Nested Tables before Expanding in Power Query
If you're an avid Power Query user you'll often need to filter nested tables before you expand them in Power Query. In this...
Read more >Examples • reactable - GitHub Pages
The table search method can be customized using the searchMethod argument in reactable() . See the Custom Filtering guide for details and examples....
Read more >How to group rows in Excel to collapse and expand them
I'm trying to figure out how to group rows, but so that when filtering, Excel considers the grouped rows together and just uses...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@matveychuk Can you please provide me an codesandbox example and is global filter working in SubRows as well?
I solved it by adding custom filter function to filterTypes
and then add filterTypes to useTable hook
and then add this custom filter to column as a string name “filterRowsWithSubrows” for value “filter”