import { Table } from '@ninetyine/react-table'
Table
should be used when data is not retrieved from an API endpoint.
It is also the basis for all other table components, such as AjaxTable
which is built on top of this.
By default the table container has the class of react-dynamic-table
.
Props
rows
: Data to be renderedrowRenderer
: How a row is renderedrowIdentifier
: A unique identifier for a rowemptyRow
: What is displayed when the dataset is emptydataManipulator
: Manipulate field values before displaying them
- Fields
fieldMap
: Map fields to be displayed as headersfieldOrder
: Define the order in which fields are displayedfieldWidths
: Define the width for each fieldfieldsToExclude
: Blacklist fields to displayfieldsToInclude
: Whitelist fields to display
- Extras
header
: Define if field headers should be displayedfooter
: Define a table footeractions
: Define actions to be displayed at the end of each row- Page Limit
pageLimit
: Define a page limit control to be displayedonPageLimitChange
: Define a page limit change callback
- Pages
pages
: Define a pagination pages control to be displayedonPageChange
: Define a page change callback
- Checkboxes
rowIsChecked
: Define a callback to determine if a row checkbox is checkedmasterIsChecked
: Define a callback to determine if the master checkbox is checkedonRowToggle
: Define a row checkbox change callbackonMasterToggle
: Define a master checkbox change callback