I define the timer in each my-progress, used to update the value of view, but the console shows the value of the constant changes, and the value of view is still not changed
check this example:
Vue.component('my-progress-bar',{ template: ` {{ percent }}% `, props: { percent: {default: 0} } }); new Vue({ el: '#app', data: {p: 50}, created: function() { var self = this; setInterval(function() { if (self.p<100) { self.p++; } }, 100); } });
Reset Bar Progress