useTableSortable
@astryxdesign/core v0.7.1 · useTableSortable
Usage
Call useTableSortable with a config object containing sort state and callback. Pass the returned plugin to Table via the plugins prop.
ts
import { useTableSortable } from '@astryx-vue/core/Table'Examples
useTableSortable — Sortable Columns
| Alice | alice@example.com | Engineer | 32 |
| Bob | bob@example.com | Designer | 28 |
| Charlie | charlie@example.com | Manager | 45 |
| Diana | diana@example.com | Engineer | 37 |
| Eve | eve@example.com | Admin | 29 |
Table with sortable columns, click headers to sort ascending or descending.