1👍
✅
You can get value of data
attribute in vue
by adding ref
attribute to your text element
<input type="text" ref="coaCode" name="code" @keyup="checkCOACode" v-model="coa_code" class="form-control" :data-table="chart_of_accounts">
And then get that attribute like
checkCOACode(e) {
e.preventDefault();
const coa = this.$refs.coaCode
const coaCode = coa.dataset.table
alert(coaCode);
return false;
},
Source:stackexchange.com