vue3.0 监听地址栏url

import { watch  } from 'vue'
import { useRouter} from 'vue-router'
setup() {
        	const route = useRouter()
    	watch(route.currentRoute, () => {
          console.log('对应操作')
        });
}

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