vue 高度 动态更新计算
calcHeight () { this.orgTreeHeight = window.innerHeight - 180 // this.tableHeight = window.innerHeight - 210 this.divHeight = window.innerHeight - 180 } }, mounted () { // console.info(‘jobOrgNum this‘, this) window.onresize = () => { this.calcHeight() } }, watch: { ‘$route‘ (to, from) { this.calcHeight() }
原文地址:https://www.cnblogs.com/pengchenggang/p/10436398.html
时间: 2024-11-01 00:39:03