this.$children.map(item=>{
if(item.list){
let temp = clearCheckItem(item.list)
// this.$store.commit("SET_MATCHLIST",[])
this.$store.commit("SET_MATCHLIST",temp)
// item.$set(item,"list",[])
item.$set(item,"list",this.ffzmatchlist)
}
})
the code view above is not updated, but the data is updated
this.$children.map(item=>{
if(item.list){
let temp = clearCheckItem(item.list)
this.$store.commit("SET_MATCHLIST",[])
this.$store.commit("SET_MATCHLIST",temp)
item.$set(item,"list",[])
item.$set(item,"list",this.ffzmatchlist)
}
})
Why is it useful to empty it and then set it up? Is this usage of
correct?
do you have any other ways to use it?