1.Vue3使用@vue,vue2使用@hook
template:
<compG @vue:mounted="doSomething"></compG>
script:
//监听子组件生命周期
let doSomething = (e: any) => {
console.log("没有啊11", e);
};
template:
<compG @vue:mounted="doSomething"></compG>
script:
//监听子组件生命周期
let doSomething = (e: any) => {
console.log("没有啊11", e);
};