id | name▲ | city | state | country | company | favoriteNumber |
---|---|---|---|---|---|---|
164 | Adrienne Horne | Snyderville | Arkansas | Gambia | Olympix | 2 |
13 | Aimee Duffy | Brownlee | Vermont | Lebanon | Repetwire | 2 |
158 | Alfreda Henry | Wilsonia | Maryland | Bhutan | Coash | 3 |
236 | Aline Sosa | Martinez | New York | Australia | Comstruct | 4 |
191 | Alison Eaton | Wauhillau | South Carolina | St Kitts & Nevis | Buzzmaker | 7 |
183 | Alyce Chavez | Bendon | Iowa | Portugal | Dognost | 8 |
115 | Amalia Nicholson | Hendersonville | Arkansas | Lesotho | Geekus | 2 |
175 | Amanda Buck | Elfrida | Nebraska | Latvia | Frosnex | 5 |
134 | Anderson Franco | Yardville | Iowa | Sweden | Wazzu | 4 |
48 | Angelica Washington | Roulette | Alabama | South Africa | Exoswitch | 3 |
To supply a default sort in Griddle we need to define a sortProperties
prop and pass into Griddle:
const sortProperties = [
{ id: 'name', sortAscending: true }
];
...
<Griddle
data={fakeData}
plugins={[plugins.LocalPlugin]}
sortProperties={sortProperties}
/>
id | name▲ | city | state | country | company | favoriteNumber |
---|---|---|---|---|---|---|
164 | Adrienne Horne | Snyderville | Arkansas | Gambia | Olympix | 2 |
13 | Aimee Duffy | Brownlee | Vermont | Lebanon | Repetwire | 2 |
158 | Alfreda Henry | Wilsonia | Maryland | Bhutan | Coash | 3 |
236 | Aline Sosa | Martinez | New York | Australia | Comstruct | 4 |
191 | Alison Eaton | Wauhillau | South Carolina | St Kitts & Nevis | Buzzmaker | 7 |
183 | Alyce Chavez | Bendon | Iowa | Portugal | Dognost | 8 |
115 | Amalia Nicholson | Hendersonville | Arkansas | Lesotho | Geekus | 2 |
175 | Amanda Buck | Elfrida | Nebraska | Latvia | Frosnex | 5 |
134 | Anderson Franco | Yardville | Iowa | Sweden | Wazzu | 4 |
48 | Angelica Washington | Roulette | Alabama | South Africa | Exoswitch | 3 |
To supply a default sort in Griddle we need to define a sortProperties
prop and pass into Griddle:
const sortProperties = [
{ id: 'name', sortAscending: true }
];
...
<Griddle
data={fakeData}
plugins={[plugins.LocalPlugin]}
sortProperties={sortProperties}
/>