You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I create a new issue for that because I think it's an important one. The input event is called twice, and the same applies to other components (t-select, ...).
<t-input :value="var" @input="val => this.var = val"/>
// or with v-model
<t-input v-model="var"/>
We can clearly see that with a log in the setter of a computed property:
data() {
return {
varProxy: '456'
}
},
computed: {
var: {
get(){
return this.varProxy
},
set(val) {
console.log('val', val) //this is called twice because input event is called twice
this.varProxy = val;
}
},
}
I guess it's because of the double watchers on the prop and localValue here... This pattern is used:
Hello, I create a new issue for that because I think it's an important one. The input event is called twice, and the same applies to other components (t-select, ...).
We can clearly see that with a log in the setter of a computed property:
I guess it's because of the double watchers on the prop and localValue here... This pattern is used:
I don't really see the point of this double watcher. Would be better to have something like this:
What do you think? thanks!
Originally posted by @loic001 in #195 (comment)
The text was updated successfully, but these errors were encountered: