Table
Column Definition
In addition to data
, you can pass an array of column
definition objects, detailed in the API.
Fresh Fruits | Veritable Vegetables | Good Grains | Delectable Dairy | Powerful Protein |
---|---|---|---|---|
Pomello | Bok Choi | Chia | Pule | Crickets |
Starfruit | Romanesco | Sorghum | Casu marzu | Barnacles |
Durian | Ramps | Teff | Vieux Lille | Inca nuts |
Persimmon | Fiddleheads | Quinoa | Milbenkase | Spirulina |
() => { const columns = [ { content: 'Fresh Fruits', key: 'Fruits' }, { content: 'Veritable Vegetables', key: 'Vegetables' }, { content: 'Good Grains', key: 'Grains' }, { content: 'Delectable Dairy', key: 'Dairy' }, { content: 'Powerful Protein', key: 'Protein' } ]; return ( <Table columns={columns} data={data} rowKey="Fruits" title="Foods of the World" hideTitle /> ); }