Table
import Table from 'frui/formats/Table'; Copy
Props
| Name | Type | Required | Notes |
|---|---|---|---|
| className | string | No | Standard HTML class names applied to all cells |
| stripe | [string, string, string] | No | Background color settings for head and rows |
| style | CSS Object | No | Standard CSS object applied to all cells |
| value | string | Yes | Default value |
Basics
The header values are based on the keys of the first row.
| id | name | age | created |
|---|---|---|---|
| 1 | John Doe | 30 | 2021-01-01 |
| 2 | Jane Doe | 25 | 2021-01-02 |
<Table
value={[
{ id: 1, name: 'John Doe', age: 30, created: '2021-01-01' },
{ id: 2, name: 'Jane Doe', age: 25, created: '2021-01-02' }
]}
stripes={['#999999', '#EFEFEF', '#CCCCCC']}
/> Copy