I am currently working with a chart implemented using vue-chart. I am facing a challenge where I need to populate the mydata array with data retrieved from the store.js file. I want to automatically push this data into the mydata array without the need for any button click or user interaction.
counter1:0,
counter2:0,
counter3:0
Here is the Chart data structure:
data(){
return {
mylabel : 'TestDataLabel',
mylabels : ['1', '2', '3','4','5','6'],
mydata : [100, 40, 60]
}
},
My goal is to dynamically update the mydata array with the values of the counters, which are being updated in another component. I am retrieving these updated values in the chart component using a computed property. How can I achieve the automatic insertion of these values into the mydata array without relying on a button click?