<template>
<uv-loading-page :loading="isLoading" loading-text="加载中..." font-size="24rpx"></uv-loading-page>
</template>
onReachBottom(async () => {
isLoading.value = true
pageNum.value = pageNum.value + 1
listCategory({ pageNum: pageNum.value, pageSize: pageSize.value, reasonable: false }).then(
response => {
categoryList.value = [...categoryList.value, ...response.rows]
}).finally(() => {
console.log("===")
isLoading.value = false
console.log("---")
console.log(isLoading)
})
})
无法正常关闭加载页
1 个回复
喜欢技术的前端 - QQ---445849201
刚试了,在onLoad中可以隐藏,检查一下 onReachBottom 有没有触发