keep-alive
在keep-alive下beforeDestroy destroyed 是无效的
需要使用
activated 页面打开时触发 每次页面打开都会触发
activated(){
console.log('页面进入时执行')
},
deactivated 页面关闭时触发
deactivated() {
console.log('页面离开时执行')
}
keep-alive
在keep-alive下beforeDestroy destroyed 是无效的
需要使用
activated 页面打开时触发 每次页面打开都会触发
activated(){
console.log('页面进入时执行')
},
deactivated 页面关闭时触发
deactivated() {
console.log('页面离开时执行')
}