因为要适配高度,在computed中动态设置了高度,然后下拉刷新的时候,就只能拉很短的距离,无法触发@refresherrefresh方法
关键代码:
:refresher-threshold="100" @refresherpulling="onPulling" @refresherrefresh="onRefresh" @refresherrestore="onRestore"
@refresherabort="onAbort" @scrolltolower="lower" name="contetn " class="bg-white myscroll">
<view v-if="isNull" class="flex solid-bottom padding justify-center text-xl">暂无数据</view> ```
js:
``` javascript
computed: {
style() {
let topHeight = this.CustomBar + 60
let sys = uni.getSystemInfoSync()
let phoneHeight = sys.windowHeight
let scrollerHeight = (phoneHeight - topHeight)
var style = `height:${scrollerHeight}px;`;
console.log(topHeight)
console.log(scrollerHeight)
return style
}
k***@163.com
请问一下,现在有解决吗?┭┮﹏┭┮
2022-09-09 13:53