I\'m trying to set a data variable in a watch handler function for an input field in a VueJs Component. I have something like this:
data() { return {
Let's try bind this to your handler
handler(date) { console.log(this.params) if (date.start) { this.params.from = moment(date.start, "YYYY/MM/DD") } if (date.end) { this.params.to = moment(date.end, "YYYY/MM/DD") } }.bind(this)