vue.js on change event code example
Example: v-on:change vue
// It is important that the watch function be named the same as the data/computed property.
new Vue({
computed: {
parsedInput () {
return parse(this.userInput)
}
},
methods: {
process () {
serverProcess(this.parsedInput);
},
},
watch: {
parsedInput() {
this.process()
}
}
})