# Toolbar

You can render a built-in Toolbar for the KendoReact TreeList component to let your end users manage the TreeList data and interact with the TreeList structure.

## Getting Started

To add a Toolbar to the TreeList, use the [`toolbar`](https://www.telerik.com/kendo-react-ui/components/treelist/api/treelistprops#toolbar) prop and pass a [`TreeListToolbar`](https://www.telerik.com/kendo-react-ui/components/treelist/api/treelisttoolbar) component as its value. Inside `TreeListToolbar`, you can render any content — buttons, inputs, or other controls.

```tsx
import { TreeList, TreeListToolbar } from '@progress/kendo-react-treelist';
import { Button } from '@progress/kendo-react-buttons';

<TreeList
    toolbar={
        <TreeListToolbar>
            <Button onClick={expandAll}>Expand All</Button>
            <Button onClick={collapseAll}>Collapse All</Button>
        </TreeListToolbar>
    }
    ...
/>
```

The following example demonstrates how to add a Toolbar to the TreeList, with **Expand All** and **Collapse All** buttons that toggle the expanded state of all rows at once.

[Demo Source](https://demos.telerik.com/kendo-react-ui/treelist/toolbar/source.txt)

## Suggested Links

* [API Reference of the TreeList](https://www.telerik.com/kendo-react-ui/components/treelist/api/treelistprops)
* [API Index of the TreeList](https://www.telerik.com/kendo-react-ui/components/treelist/api)
