I have successfully created the table using the code below.
My issue is with the header… I can get the background set to red, but I haven’t been able to set the foreground color. What’s missing from my code?
<template>
<v-data-table
fixed-header
:header-props="{ class: 'bg-red'}"
hide-default-footer
:headers="headers"
:items="items">
</v-data-table>
</template>
<script>
export default {
data() {
return {
payload: {}
}
},
watch: {
msg: function(){
if(this.msg.payload != undefined) {
this.payload = this.msg.payload;
}
}
},
computed: {
headers() {
return [
{text: 'Device Name', value: 'name'},
{text: 'Model', value: 'model'},
{text: 'Firmware', value: 'firmware'}
]
},
items() {
return this.payload
}
},
}
</script>