watch(() => [state.formState.name,state.formState.post], (newValue,oldValue)=>{
console.log(newValue); //是数组
console.log(oldValue)
})
vue3使用watch监听多个数据
最新推荐文章于 2024-06-05 16:27:40 发布
watch(() => [state.formState.name,state.formState.post], (newValue,oldValue)=>{
console.log(newValue); //是数组
console.log(oldValue)
})