React Suite Table Component Last Updated : 11 Apr, 2022 Comments Improve Suggest changes Like Article Like Report React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Table component allows the user to display rows of data. We can create tables using this component. We can use the following approach in ReactJS to use the React Suite Table Component. Table Props: affixHeader: It is used to affix the table header to the specified location on the page.affixHorizontalScrollbar: It is used to affix the table horizontal scrollbar to specified position on the page.autoHeight: It is used for the automatic height.bodyRef: It is used to denote a ref attached to the table body element.bordered: It is used to show the border.cellBordered: It is used to show the cell border.data: It is used to denote the Table data.defaultExpandAllRows: It is used to expand all nodes by default.defaultExpandedRowKeys: It is used to specify the default expanded row by rowkey.defaultSortType: It is used to denote the sort type.expandedRowKeys: It is used to specify the default expanded row by rowkey.headerHeight: It is used to denote the Table Header Height.height: It is used to denote the Table height.hover: It is used to denote that the row of the table has a mouseover effect.isTree: It is used to show as a Tree table.loading: It is used to show loading.minHeight: It is used to denote the minimum height.onDataUpdated: It is a callback function that is triggered after table data update.onExpandChange: It is a callback function that is triggered in the expanded node while expanding.onRowClick: It is a callback function that is triggered after the row and returns to rowDate.onScroll: It is a callback function that is triggered for scroll bar scrolling.onSortColumn: Callback function for the sort sequence to return the value sortColumn, sortType.renderEmpty: It is used to customize data in empty display content.renderLoading: It is used to customize the display content in the data load.renderRowExpanded: It is used to customize what you can do to expand a zone.renderTreeToggle: It is a callback function that is triggered in the expanded node while toggling.rowClassName: It is used to add an optional extra class name to the row.rowExpandedHeight: It is used to set the height of an expandable area.rowHeight: It is used to denote the Row height.rowKey: It is used to denote the row key.shouldUpdateScroll: It is used to indicate whether to update the scroll bar after data update or not.showHeader: It is used to display header.sortColumn: It is used to the Sort column name.sortType: It is used to denote the sort type (Controlled).virtualized: It is used to effectively render large tabular data.width: It is used to denote the Table width.wordWrap: It is used to make the cell wraps automatically.Table.Column Props align: It is used for the alignment.colSpan: Column cells to merge when the data key value for the merged column is null or undefined.fixed: It is used for the fixed column.flexGrow: Set column width automatically adjusts when set flexGrow cannot set resizable and width propertyminWidth: It is used to set a minimum width by min-width when you use flexGrow.onResize: It is a callback function that is triggered after column width change.resizable: It is used for the customizable Resize Column width.sortable: It is used to denote whether it is Sortable or not.treeCol: It is used to denote a column of a tree.verticalAlign: It is used for vertical alignment.width: It is used to denote the column width.Table.ColumnGroup Props: align: It is used for the alignment.fixed: It is used for the fixed column group.verticalAlign: It is used for vertical alignment.header: It is used for the group header.  Table.Cell Props: dataKey: It is used to denote the data binding key.rowData: It is used to denote the row data.rowIndex: It is used to denote the row number.Table.Pagination Props: activePage: It is used to configure the current page number.disabled: It is used to disable the component.displayLength: Configure how many lines of entries per page to display, corresponding to lengthMenufirst: It is used to show the first-page button.last: It is used to show the last-page button.lengthMenu: It is used to denote the paging display row number configuration.maxButtons: It is used to configure the maximum number of display buttons.next: It is used to show the Next Page button.onChangeLength: It is a callback function that triggers when the lengthMenu value changes.onChangePage: It is a callback function that triggers when the page changes.prev: It is used to show the Previous Page button.renderLengthMenu: It is used for the custom menu.renderTotal: It is used for the custom total.reverse: It is used to reverse the start and end position.showInfo: It is used to show paging information.showLengthMenu: It is used to display the Dropdown menu.total: It is used to denote the total number of data entries.Creating React Application And Installing Module: Step 1: Create a React application using the following command: npx create-react-app foldername Step 2: After creating your project folder i.e. foldername, move to it using the following command: cd foldername Step 3: After creating the ReactJS application, Install the required module using the following command: npm install rsuite Project Structure: It will look like the following. Project StructureExample: Now write down the following code in the App.js file. Here, App is our default component where we have written our code. App.js import React from 'react' import 'rsuite/dist/styles/rsuite-default.css'; import { Table } from 'rsuite'; const { Column, HeaderCell, Cell } = Table; export default function App() { // Sample table data const sampleData = [ { firstName: 'Gourav', lastName: 'Hammad', city: 'Mhow' }, { firstName: 'Rithik', lastName: 'Verma', city: 'Indore' }, { firstName: 'Kartik', lastName: 'Malik', city: 'Raipur' }, { firstName: 'Nikhil', lastName: 'Kapoor', city: 'Rau' }, { firstName: 'Ayush', lastName: 'Singh', city: 'Dewas' } ] return ( <div style={{ display: 'block', width: 700, paddingLeft: 30 }}> <h4>React Suite Table Component</h4> <Table height={500} data={sampleData} > <Column width={200}> <HeaderCell>First Name</HeaderCell> <Cell dataKey="firstName" /> </Column> <Column width={200}> <HeaderCell>Last Name</HeaderCell> <Cell dataKey="lastName" /> </Column> <Column width={200}> <HeaderCell>City</HeaderCell> <Cell dataKey="city" /> </Column> </Table> </div> ); } Step to Run Application: Run the application using the following command from the root directory of the project: npm startOutput: Now open your browser and go to http://localhost:3000/, you will see the following output: Reference: https://rsuitejs.com/components/table/ Comment More infoAdvertise with us Next Article React Suite Tag Component gouravhammad Follow Improve Article Tags : JavaScript Web Technologies ReactJS React-Suite Components React-Suite Data Display React-Suite +2 More Similar Reads CalendarReact Suite Calendar ComponentReact Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Calendar component allows the user to display data by the calendar. It is treated as a container for displaying data in the form of a calendar. We can use the f 2 min read React Suite DateRangePicker Show One CalendarReact Suite is a front-end UI framework that has a set of React components that developers can use in their react app to fasten the development process. It supports all the major browsers like Chrome, Safari, Firefox, Brave, etc. In this example, we will see React Suite DateRangePicker Show One Cale 3 min read React Suite Carousel Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Carousel component allows the user to display a set of elements in a carousel. We can use the following approach in ReactJS to use the React Suite Carousel Compo 2 min read DividerReact Suite Vertical DividerReact Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Divider allows the user to separate UI components from each other. Different types of dividers exist: Vertical Divider: Divides the content with a vertical line. 3 min read React Suite Dropdown Divider and PanelReact Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Dropdown component allows the user to provide navigation that uses a select picker if you want to select a value. Divide and Panel are used in Dropdown to set d 3 min read React Suite Divider With TextReact Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Divider allows the user to separate UI components from each other. Divider with Text: The user can provide context to the separation using this. Approach: Let u 3 min read React Suite Divider ComponentReact Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Divider component allows the user to display a dividing line. We can use the following approach in ReactJS to use the React Suite Divider Component. Divider Prop 2 min read React Suite Stack DividersReact suite is a library of React components, sensible UI design, and a friendly development experience. It is supported in all major browsers. It provides pre-built components of React which can be used easily in any web application. In this article, we'll learn about React Suite Stack Dividers. A 2 min read React Suite List Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. List component allows the user to display a list. We can use the following approach in ReactJS to use the React Suite List Component. List Props: bordered: It is 2 min read React Suite Table Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Table component allows the user to display rows of data. We can create tables using this component. We can use the following approach in ReactJS to use the React 6 min read React Suite Tag Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Tag component allows the user to provide a Tag for categorizing or markup. We can use the following approach in ReactJS to use the React Suite Tag Component. Tag 2 min read React Suite Timeline Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. The timeline component allows the user to provide a vertical display timeline. We can use the following approach in ReactJS to use the React Suite Timeline Compo 2 min read React Suite Panel Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Panel component allows the user to display a content panel that supports folding panels. We can use the following approach in ReactJS to use the React Suite Pane 2 min read React Suite Animation Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. Animation component allows the user to handle animation components. It provides various animations like fade, bounce, slide, collapse, and transition effects. We 7 min read React Suite DOMHelper Component React Suite is a popular front-end library with a set of React components that are designed for the middle platform and back-end products. DOMHelper component allows the user to directly manipulate the DOM for some considerations. We can use the following approach in ReactJS to use the React Suite D 3 min read Like