scrollH: 0,
-----------------------------------------------------
onLoad: function() {
var self = this;
wx.getSystemInfo({
success: function(res) {
let scrollH = res.windowHeight;
self.setData({
scrollH: 0.7 * scrollH
});
}
});
},
-------------------------------------------
<scroll-view scroll-y="true" bindscrolltolower="searchScrollLower" style="height:{{scrollH}}px;">
scroll-view需要固定高度,100%不行,比 res.windowHeight 大不行,略小于也不行,得多小一些。