-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[question] Why is "filterMode='server'" not allowed when treeData is enabled ? #6873
Comments
When you have We could enable server side filtering with tree data, but you would always have to return the whole tree and to re-implement all the logic of the visible groups / visible children. |
Thanks for coming back so quickly on this! Just to provide a bit more context, my approach to filtering is the following:
Now with I feel like the choice of using either 'client' or 'server' filter-mode should be left to the developer themselves rather than it being set in stone internally within the component no? |
As long as it is possible yes, this warning is meant to be temporary, waiting for a clean implementation of the server-side filtering with tree data. Right now the grid filters the rows on the client even when I do think however that the clean, long term solution is to allow people to only return the top level rows (filtered in the client or on the server) and then to have a callback to fetch the children of a group (which would be called whenever the filtering changes if the filtering is on the server or only once if the filtering is on the client). |
Thanks for the detailed reply, looking forward to the new lazy loading features! |
Order ID 💳
54054
Duplicates
Latest version
The problem in depth 🔍
Hi MUI team,
I'm currently using the DataGridPro TreeData feature to display a large volume of data and it works perfectly. However I do receive the following warning when in development mode:
Warning: Failed prop type: MUI: The filterMode="server" prop is not available when the treeData is enabled.
However despite the aforementioned warning, the rows still appear to be filtered server-side and so still works in the way I would like it to.This leads me to ask the following: what is the point of this warning? Will enabling both server-side filtering and tree-data cause some kind of rendering issue internally? If not, can we then just remove this warning from the codebase?
Your environment 🌎
`npx @mui/envinfo`
The text was updated successfully, but these errors were encountered: