1***@qq.com
1***@qq.com
  • 发布:2023-12-14 14:06
  • 更新:2023-12-14 14:54
  • 阅读:118

#插件讨论# 【 uv-loading-page 加载页 全面兼容小程序、nvue、vue2、vue3等多端 - uv_UI 】无法正常关闭加载页

分类:HBuilderX
<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)  
        })  
    })

无法正常关闭加载页

2023-12-14 14:06 负责人:无 分享
已邀请:
喜欢技术的前端

喜欢技术的前端 - QQ---445849201

刚试了,在onLoad中可以隐藏,检查一下 onReachBottom 有没有触发

<template>  
    <view class="content">  
        测试uv-loading-page  
        <uv-loading-page :loading="isLoading" loading-text="加载中..." font-size="24rpx"></uv-loading-page>  
    </view>  
</template>  

<script setup lang="ts">  
    import { onLoad } from '@dcloudio/uni-app'  
    import {ref} from 'vue'  
    let isLoading = ref(true)  

    onLoad(() => {  
        setTimeout(()=>{  
            isLoading.value = false  
        },3000)  

    })  

</script>  

<style>  

</style>

要回复问题请先登录注册