You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/content/docs/1.getting-started/3.migration/2.v3.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -469,7 +469,7 @@ The default slot now only customizes the trigger, with additional slots for fine
469
469
</template>
470
470
```
471
471
472
-
- The `Table` component now uses [TanStack Table](https://tanstack.com/table/latest){target="_blank" rel="noopener"} under the hood. The `rows` prop has been renamed to `data`:
472
+
- The `Table` component now uses [TanStack Table](https://tanstack.com/table/v8){target="_blank" rel="noopener"} under the hood. The `rows` prop has been renamed to `data`:
Copy file name to clipboardExpand all lines: docs/content/docs/2.components/table.md
+16-16Lines changed: 16 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,15 +10,15 @@ links:
10
10
avatar:
11
11
src: https://github.com/tanstack.png
12
12
loading: lazy
13
-
to: https://tanstack.com/table/latest
13
+
to: https://tanstack.com/table/v8
14
14
- label: GitHub
15
15
icon: i-simple-icons-github
16
16
to: https://github.com/nuxt/ui/blob/v4/src/runtime/components/Table.vue
17
17
---
18
18
19
19
## Usage
20
20
21
-
The Table component is built on top of [TanStack Table](https://tanstack.com/table/latest) and is powered by the [useVueTable](https://tanstack.com/table/latest/docs/framework/vue/vue-table#usevuetable) composable to provide a flexible and fully type-safe API.
21
+
The Table component is built on top of [TanStack Table v8](https://tanstack.com/table/v8) and is powered by the [useVueTable](https://tanstack.com/table/v8/docs/framework/vue/vue-table#usevuetable) composable to provide a flexible and fully type-safe API.
22
22
23
23
It renders your data as rows and columns and supports sorting, filtering, pagination, row selection, expansion, grouping, pinning and virtualization, so you can build everything from a simple data table to a fully featured data grid.
24
24
@@ -81,7 +81,7 @@ props:
81
81
82
82
### Columns
83
83
84
-
Use the `columns` prop as an array of [ColumnDef](https://tanstack.com/table/latest/docs/api/core/column-def) objects with properties like:
84
+
Use the `columns` prop as an array of [ColumnDef](https://tanstack.com/table/v8/docs/api/core/column-def) objects with properties like:
85
85
86
86
-`accessorKey`: [The key of the row object to use when extracting the value for the column.]{class="text-muted"}
87
87
-`header`: [The header to display for the column. If a string is passed, it can be used as a default for the column ID. If a function is passed, it will be passed a props object for the header and should return the rendered header value (the exact type depends on the adapter being used).]{class="text-muted"}
@@ -123,7 +123,7 @@ When rendering components with `h`, you can either use the `resolveComponent` fu
123
123
124
124
### Meta
125
125
126
-
Use the `meta` prop as an object ([TableMeta](https://tanstack.com/table/latest/docs/api/core/table#meta)) to pass properties like:
126
+
Use the `meta` prop as an object ([TableMeta](https://tanstack.com/table/v8/docs/api/core/table#meta)) to pass properties like:
127
127
128
128
-`class`:
129
129
-`tr`: [The classes to apply to the `tr` element.]{class="text-muted"}
@@ -274,7 +274,7 @@ class: '!p-0'
274
274
275
275
### With expandable rows
276
276
277
-
You can add a new column that renders a [Button](/docs/components/button) component inside the `cell` to toggle the expandable state of a row using the TanStack Table [Expanding APIs](https://tanstack.com/table/latest/docs/api/features/expanding).
277
+
You can add a new column that renders a [Button](/docs/components/button) component inside the `cell` to toggle the expandable state of a row using the TanStack Table [Expanding APIs](https://tanstack.com/table/v8/docs/api/features/expanding).
278
278
279
279
::caution
280
280
You need to define the `#expanded` slot to render the expanded content which will receive the row as a parameter.
@@ -302,7 +302,7 @@ You could also add this action to the [`DropdownMenu`](/docs/components/dropdown
302
302
303
303
### With grouped rows
304
304
305
-
You can group rows based on a given column value and show/hide sub rows via some button added to the cell using the TanStack Table [Grouping APIs](https://tanstack.com/table/latest/docs/api/features/grouping).
305
+
You can group rows based on a given column value and show/hide sub rows via some button added to the cell using the TanStack Table [Grouping APIs](https://tanstack.com/table/v8/docs/api/features/grouping).
306
306
307
307
#### Important parts:
308
308
@@ -326,7 +326,7 @@ class: '!p-0'
326
326
327
327
### With row pinning :badge{label="4.6+"class="align-text-top"}
328
328
329
-
You can add a column that renders a [Button](/docs/components/button) component inside the `cell` to toggle the pinning state of a row using the TanStack Table [Row Pinning APIs](https://tanstack.com/table/latest/docs/api/features/row-pinning). Pinned rows will stay at the top or bottom of the table regardless of sorting or filtering.
329
+
You can add a column that renders a [Button](/docs/components/button) component inside the `cell` to toggle the pinning state of a row using the TanStack Table [Row Pinning APIs](https://tanstack.com/table/v8/docs/api/features/row-pinning). Pinned rows will stay at the top or bottom of the table regardless of sorting or filtering.
330
330
331
331
::component-example
332
332
---
@@ -350,7 +350,7 @@ You can use the `row-pinning` prop to control the pinning state of the rows (can
350
350
351
351
### With row selection
352
352
353
-
You can add a new column that renders a [Checkbox](/docs/components/checkbox) component inside the `header` and `cell` to select rows using the TanStack Table [Row Selection APIs](https://tanstack.com/table/latest/docs/api/features/row-selection).
353
+
You can add a new column that renders a [Checkbox](/docs/components/checkbox) component inside the `header` and `cell` to select rows using the TanStack Table [Row Selection APIs](https://tanstack.com/table/v8/docs/api/features/row-selection).
354
354
355
355
::component-example
356
356
---
@@ -471,7 +471,7 @@ class: '!p-0'
471
471
472
472
### With column sorting
473
473
474
-
You can update a column `header` to render a [Button](/docs/components/button) component inside the `header` to toggle the sorting state using the TanStack Table [Sorting APIs](https://tanstack.com/table/latest/docs/api/features/sorting).
474
+
You can update a column `header` to render a [Button](/docs/components/button) component inside the `header` to toggle the sorting state using the TanStack Table [Sorting APIs](https://tanstack.com/table/v8/docs/api/features/sorting).
475
475
476
476
::component-example
477
477
---
@@ -509,7 +509,7 @@ In this example, we use a function to define the column header but you can also
509
509
510
510
### With column pinning
511
511
512
-
You can update a column `header` to render a [Button](/docs/components/button) component inside the `header` to toggle the pinning state using the TanStack Table [Pinning APIs](https://tanstack.com/table/latest/docs/api/features/row-pinning).
512
+
You can update a column `header` to render a [Button](/docs/components/button) component inside the `header` to toggle the pinning state using the TanStack Table [Column Pinning APIs](https://tanstack.com/table/v8/docs/api/features/column-pinning).
513
513
514
514
::note
515
515
A pinned column will become sticky on the left or right side of the table. When using column pinning, you should define explicit `size` values for your columns to ensure proper column width handling, especially with multiple pinned columns.
@@ -534,7 +534,7 @@ You can use the `column-pinning` prop to control the pinning state of the column
534
534
535
535
### With column visibility
536
536
537
-
You can use a [DropdownMenu](/docs/components/dropdown-menu) component to toggle the visibility of the columns using the TanStack Table [Column Visibility APIs](https://tanstack.com/table/latest/docs/api/features/column-visibility).
537
+
You can use a [DropdownMenu](/docs/components/dropdown-menu) component to toggle the visibility of the columns using the TanStack Table [Column Visibility APIs](https://tanstack.com/table/v8/docs/api/features/column-visibility).
538
538
539
539
::component-example
540
540
---
@@ -554,7 +554,7 @@ You can use the `column-visibility` prop to control the visibility state of the
554
554
555
555
### With column filters
556
556
557
-
You can use an [Input](/docs/components/input) component to filter per column the rows using the TanStack Table [Column Filtering APIs](https://tanstack.com/table/latest/docs/api/features/column-filtering).
557
+
You can use an [Input](/docs/components/input) component to filter per column the rows using the TanStack Table [Column Filtering APIs](https://tanstack.com/table/v8/docs/api/features/column-filtering).
558
558
559
559
::component-example
560
560
---
@@ -574,7 +574,7 @@ You can use the `column-filters` prop to control the filters state of the column
574
574
575
575
### With global filter
576
576
577
-
You can use an [Input](/docs/components/input) component to filter the rows using the TanStack Table [Global Filtering APIs](https://tanstack.com/table/latest/docs/api/features/global-filtering).
577
+
You can use an [Input](/docs/components/input) component to filter the rows using the TanStack Table [Global Filtering APIs](https://tanstack.com/table/v8/docs/api/features/global-filtering).
578
578
579
579
::component-example
580
580
---
@@ -593,9 +593,9 @@ You can use the `global-filter` prop to control the global filter state (can be
593
593
594
594
### With pagination
595
595
596
-
You can use a [Pagination](/docs/components/pagination) component to control the pagination state using the [Pagination APIs](https://tanstack.com/table/latest/docs/api/features/pagination).
596
+
You can use a [Pagination](/docs/components/pagination) component to control the pagination state using the [Pagination APIs](https://tanstack.com/table/v8/docs/api/features/pagination).
597
597
598
-
There are different pagination approaches as explained in [Pagination Guide](https://tanstack.com/table/latest/docs/guide/pagination#pagination-guide). In this example, we use client-side pagination so we need to manually pass `getPaginationRowModel()`{lang="ts-type"} function.
598
+
There are different pagination approaches as explained in [Pagination Guide](https://tanstack.com/table/v8/docs/guide/pagination#pagination-guide). In this example, we use client-side pagination so we need to manually pass `getPaginationRowModel()`{lang="ts-type"} function.
599
599
600
600
::component-example
601
601
---
@@ -780,7 +780,7 @@ This will give you access to the following:
0 commit comments