diff --git a/docs/content/4.data/1.table.md b/docs/content/4.data/1.table.md index 357cc28efc..09fde3aed3 100644 --- a/docs/content/4.data/1.table.md +++ b/docs/content/4.data/1.table.md @@ -545,7 +545,7 @@ Even though you can customize the sort button as mentioned in the [Sortable](#so ### `-data` -Use the `#-data` slot to customize the data cell of a column. You will have access to the `row` and `column` properties in the slot scope. +Use the `#-data` slot to customize the data cell of a column. You will have access to the `row`, `column` and `getRowData` properties in the slot scope. You can for example create an extra column for actions with a [Dropdown](/elements/dropdown) component inside or change the color of the rows based on a selection. diff --git a/src/runtime/components/data/Table.vue b/src/runtime/components/data/Table.vue index dfcfca727c..9bdf9210c6 100644 --- a/src/runtime/components/data/Table.vue +++ b/src/runtime/components/data/Table.vue @@ -55,8 +55,8 @@ - - {{ row[column.key] }} + + {{ getRowData(row, column.key) }} @@ -69,9 +69,8 @@