自定义组件生命周期res.height有的时候报nullready: function () {var that = thisvar query = wx.createSelectorQuery().in(this)query.select('.question').boundingClientRect(function (res) { that.setData({ questionHeight: res.height })}).exec()// console.log(that.data.questionHeight)}
添加回答
举报
0/150
提交
取消