Hi,
I am struggling with k-table
component. The goal is to have a sortable table with pagination.
<template>
<section>
<k-table
:columns="{
name: { label: 'Name', type: 'text'},
email: { label: 'E-Mail', type: 'text'}
}"
:rows=data
:empty=empty
:index=true
:sortable=true
/>
</section>
</template>
<script>
export default {
data() {
return {
data: [
['Lorem1', 'lorem1@host.com'],
['Lorem2', 'lorem2@host.com'],
['Lorem3', 'lorem3@host.com'],
],
empty: 'No data...'
}
}
};
</script>
<style>
</style>
A simple example how I tried to use the k-table
component. Unfortunately it doesn’t work. What I am getting is the following error:
can’t convert undefined to object
which point to compiled panel/index.js
The line probably not important, but if necessary I can provide the code.
Can someone please point me to the right direction on how to use k-table component? An example would be very welcome.
Thank you in advance!