Skip to content

useTableSortable

@astryxdesign/core v0.7.1 · useTableSortable

使用方法 ​

把排序状态和它的回调放进配置对象,交给 useTableSortable。它返回的插件通过 plugins 属性传给 Table。

ts
import { useTableSortable } from '@astryx-vue/core/Table'

示例 ​

useTableSortable —— 可排序的列

Alicealice@example.comEngineer32
Bobbob@example.comDesigner28
Charliecharlie@example.comManager45
Dianadiana@example.comEngineer37
Eveeve@example.comAdmin29

列可以排序的表格。点表头就在升序和降序之间切换。