diff --git a/docs/TreeWithDetails.md b/docs/TreeWithDetails.md index a5995f6a5cb..f34e2f9deea 100644 --- a/docs/TreeWithDetails.md +++ b/docs/TreeWithDetails.md @@ -245,17 +245,18 @@ If you want to allow user to reorder nodes in the tree, simply add the `draggabl export const CategoriesList = () => ; ``` - -### `filter` +## `filter` You can choose to permanently filter the tree to display only a sub tree. For instance, imagine you have one `employees` resource with a `department` field, and you want to display a tree for the Finance department. Use the `filter` prop to filter the tree: {% raw %} + ```jsx const EmployeeList = () => ; ``` + {% endraw %} **Note**: This only works if the filter field allows to extract a subtree with its own root node. If you use the `filter` prop to display a sparse selection of nodes (e.g. only the `male` employees), dragging nodes in this tree will not work as expected.