The React TreeGrid is a feature-rich control used to visualize self-referential, hierarchical data effectively in a tabular format (a tree-like structure). Its rich feature set includes many functionalities: data binding, virtualization, editing, sorting, searching, filtering, infinite scrolling, paging, frozen rows and columns, exporting to multiple formats, aggregating rows, and more.
Bind data seamlessly with various local and remote data sources such as JSON, RESTful services, OData services, and WCF services. React Tree Grid control uses the data manager to handle data and supports customizing data requests and processing.
The React Tree Grid has optimized design for high-performance. It loads millions of records in just a second without any performance degradation with the help of row and column virtualization.
Columns define the schema of a data source in React Tree Grid. Features include formatting, column definitions, text wrapping, column chooser, column menu, column reordering, and other important features.
Through paging, a segment of data can be viewed from the assigned data source. The React Tree Grid offers built-in pager UI with options to customize its entire UI. It also has an on-demand paging mode for effective data retrieval from remote web services.
The React Tree Grid allows users to sort a column by simply clicking on the header. A Ctrl + header click performs multi-sorting. Sort data in either ascending or descending order.
Filtering helps view specific or related records that meet a given filtering criteria. It supports various filter types that include powerful Excel-like filter. The React Tree Grid filter allows users to choose appropriate filter types, define their own custom filtering logic, and customize the filtering UI based on their application needs. Filtering with related parent or child records can be defined.
React TreeGrid allows selecting rows or cells. One or more rows or cells can also be selected by holding Ctrl or Command, or programmatically.
Rows in Tree Grid represents each data object information from the data source. It supports expanding / collapsing child rows, reordering of rows, indent / outdent rows to change its hierarchy levels and much more features.
The React TreeGrid provides full support to create, read, update, and delete operations (CRUD). In addition to built-in editor components to edit a particular column value, using template support users can create custom editor components that suit their application needs. It performs editing operations with JSON collection or remote data service with the help of data manager.
Aggregates for column values can easily be displayed using the aggregate feature. Aggregates can be customized to show their value in every hierarchy with a set of predefined summary types.
Frozen columns are visible at the left or right or both the sides of the tree grid and make the remaining grid content scrollable. It is mainly used to compare cell values.
You can search the records using the search method. Integrate search text box in the React TreeGrid’s toolbar by adding search items.
The React Tree Grid has a highly responsive layout and a finely optimized design for desktops, touch screens, and smart phones.
User-friendly touch gestures and an interactive UI design help produce the best user experience. All Tree Grid features work on touch devices with zero configuration.
The React Tree Grid pager acts intelligently and changes its complete UI responsively based on the tree grid dimension. Its optimized design provides the best UI interaction in different devices.
The React Tree Grid user interface is customized and redesigned for great views and usability on small screens. Filter, search, and edit dialogs are adaptive to the screen size.
React TreeGrid component allows you to set tooltips for treegrid cells. Hover over the tree nodes to display tooltip text.
Easily export the Tree Grid control in various file formats such as Excel, PDF, or CSV. Users can also programmatically customize the exported document.
Users can print data either by using the print option from the toolbar or programmatically. Print all the rows of a React TreeGrid regardless of the number of pages or print the currently viewed page alone.
Row height is a major factor when displaying the number of records in the view port, and it is effortlessly customizable based on the application’s UI requirement. It is also possible to set row height conditionally.
The clipboard provides an option to copy selected rows or cells’ data into the clipboard. Use Ctrl+C and Ctrl+Shift+H key combinations to copy data with and without headers, respectively.
The context menu improves user action with React Tree Grid using popup menu. It appears when the cell, header, or pager is right clicked. In addition to built-in default menu items, it allows you to add custom context menu items.
Allows changing the React Tree Grid size by setting the width and height properties. Horizontal and vertical scrollbars will appear when the content overflows the React Tree Grid element. For the React Tree Grid to fill its parent container, the user must simply set the height and width to 100%.
Using templates, users can create custom UI. It provides various template options to create custom headers, custom cell contents, custom rows, detail rows, toolbars, and custom editors for edit action.
Stacked headers allow grouping and visualizing column headers in a stacked manner. There is no limit to the number of columns that can be stacked. Allows the user to perform all React TreeGrid actions, even when the columns are stacked.
Several built-in SASS-based themes are available such as Fluent, Tailwind CSS, Bootstrap 5, Bootstrap 4, Bootstrap, Material, Fabric, and High Contrast. Simplify theme customization either by overriding the existing SASS styling or creating custom themes by using the Theme Studio application.
The Tree Grid ensures that every cell is keyboard accessible. Major features like expanding or collapsing child rows, sort, select, and edit can be performed using keyboard commands alone; no mouse interaction required. This helps in creating highly accessible applications using this component.
The React Tree Grid has complete WAI-ARIA accessibility support. Its UI includes high-contrast visual elements, helping visually impaired people have the best viewing experience. Also, the valid UI descriptions are easily accessible through assistive technologies such as screen readers.
Tree Grid in React enables users from different locales to use it by formatting the date, currency, and numbering to suit local preferences. It uses the internalization (i18n) library to handle value formatting.
Right-to-left rendering allows displaying the text and layout of the React Tree Grid from right to left. This improves the user experience and accessibility for RTL languages.
Based on their needs, users can allow localizing all the strings that are used in the user interface of React Tree Grid control. It uses the localization (l10n) library to localize UI strings.
Easily get started with the React TreeGrid using a few simple lines of TSX code example as demonstrated below. Also explore our React TreeGrid Example that shows you how to render and configure a TreeGrid in React.
import { ColumnDirective, ColumnsDirective, TreeGridComponent } from '@syncfusion/ej2-react-treegrid';
import * as React from 'react';
import './App.css';
import { sortData } from './datasource';
export default class App extends React.Component<{}, {}>{
public render() {
return <TreeGridComponent dataSource={sortData} treeColumnIndex={1} childMapping= 'subtasks'>
<ColumnsDirective>
<ColumnDirective field='Category' headerText='Category' width='150'/>
<ColumnDirective field='orderName' headerText='Order Name' width='170'/>
<ColumnDirective field='orderDate' headerText='Order Date' width='130' format='yMd' textAlign='Right' type='date' />
<ColumnDirective field='price' headerText='Price' width='100' textAlign='Right' type='number' format='C0' />
</ColumnsDirective>
</TreeGridComponent>
}
};
The Tree Grid component is also available in Blazor, Vue, Angular, and React frameworks. Check out the different Tree Grid platforms from the links below,
You can find our React TreeGrid demo, which demonstrates how to render and configure the TreeGrid.
No, this is a commercial product and requires a paid license. However, a free community license is also available for companies and individuals whose organizations have less than $1 million USD in annual gross revenue and five or fewer developers.
A good place to start would be our comprehensive getting started documentation.
Greatness—it’s one thing to say you have it, but it means more when others recognize it. Syncfusion is proud to hold the following industry awards.