//放置与data同级 options: { styleIsolation: 'shared' },
<template> <view class='container'></view> </template> <script> export default { props: {}, data: () => ({}), computed: {}, methods: {}, watch: {}, // 组件加载完成 onLoad(options){ }, // 组件显示 onShow(){ }, options: { styleIsolation: 'shared' }, // 组件周期函数--监听组件挂载完毕 mounted() {}, // 组件周期函数--监听组件数据更新之前 beforeUpdate() {}, // 组件周期函数--监听组件数据更新之后 updated() {}, // 组件周期函数--监听组件激活(显示) activated() {}, // 组件周期函数--监听组件停用(隐藏) deactivated() {}, // 组件周期函数--监听组件销毁之前 beforeDestroy() {}, }; </script> <style lang='scss' scoped> .container { width: 100%; min-height: calc(100vh - var(--window-bottom)); } </style>
来源:https://blog.csdn.net/weixin_43245095/article/details/126769476
标签:uniapp,--,周期函数,deep,options,组件,监听 From: https://www.cnblogs.com/brillant/p/18572225