I am trying to watch a list that contains sublists, and some <input>
elements can modify the sublist effectively.
<div id="app">
<div v-for="sub in list">
<div v-for="(v,idx) in sub">
<input v-model="sub[idx]"/>
</div>
</div>
</div>
<script>
new Vue({
el: "#app",
data: {
list: [['one','two']]
},
watch: {
list: funtion(){
console.log('change')
}
}
})
</script>
Despite modifying the input, the watcher is not triggered.