vue3怎么使用watch

import {  watch } from 'vue'
watch(numVal, (newVal,oldVal) => {
  console.log("newVal",newVal)
})

你可能感兴趣的:(vue.js,前端,javascript)