VUE 获取窗口改变时的大小

mounted() {

 

 
 
const that = this;
window.onresize = function temp() {
that.clientHeight = `${document.documentElement.clientHeight}`;
console.log(that.clientHeight)
 
};
},
posted @ 2018-01-27 16:16  丁丶丁  阅读(744)  评论(0编辑  收藏  举报