<script setup>
import { watchEffect } from 'vue';
const props = defineProps({
showDrawer: {
type: Boolean,
defult: false,
},
dateType: {
type: String,
},
});
watchEffect(()=>{
console.log('qqqqqq监听',props.showDrawer);
});
</script>
使用watchEffect 进行监听!!!!