After reviewing the Vue $refs documentation, I am still unsure of how to retrieve the value of an id. When I check the console, I see that there is no object associated with it. Despite my efforts, using
console.log(this.$refs.dataInfo.id)
returns undefined
.
Take a look at the following image: https://i.sstatic.net/dGudb.png
Javascript file:
console.log(this.$refs)
HTML file:
<tab-item v-for="item in category" :id="item.id" ref="dataInfo">{{item.name}}</tab-item>