Skip to content

Commit 60a4cca

Browse files
authored
docs(table): minor updates to table complete example (#2997)
1 parent ff94b10 commit 60a4cca

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/components/table/README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2035,6 +2035,7 @@ differences between operating systems, this too is not a preventable default beh
20352035
{ key: 'isActive', label: 'is Active' },
20362036
{ key: 'actions', label: 'Actions' }
20372037
],
2038+
totalRows: 1,
20382039
currentPage: 1,
20392040
perPage: 5,
20402041
pageOptions: [5, 10, 15],
@@ -2046,9 +2047,6 @@ differences between operating systems, this too is not a preventable default beh
20462047
}
20472048
},
20482049
computed: {
2049-
totalRows() {
2050-
return this.items.length
2051-
},
20522050
sortOptions() {
20532051
// Create an options list from our fields
20542052
return this.fields
@@ -2058,6 +2056,10 @@ differences between operating systems, this too is not a preventable default beh
20582056
})
20592057
}
20602058
},
2059+
mounted() {
2060+
// Set the initial number of items
2061+
totalRows = this.items.length
2062+
},
20612063
methods: {
20622064
info(item, index, button) {
20632065
this.modalInfo.title = `Row index: ${index}`

0 commit comments

Comments
 (0)