可以在页面转换时加入一个闪屏页实现,通过router.replaceUrl用需要切换的页面替换这个闪屏页实现,如:@Entry @Component export struct LoadingPage { @Prop flag: boolean; build() { Row() { LoadingProgress().color(Color.White).width(50).height(50) } .height(this.flag ? '100%' : 0) .width('100%') .position({ x: 0, y: 0 }) .backgroundColor('#4D000000') .justifyContent(FlexAlign.Center) } }replaceUrl参考文档:https://developer.huawei.com/consumer/cn/doc/harmonyos-references-V5/js-apis-router-V5
可以在页面转换时加入一个闪屏页实现,通过router.replaceUrl用需要切换的页面替换这个闪屏页实现,如:
replaceUrl参考文档:https://developer.huawei.com/consumer/cn/doc/harmonyos-references-V5/js-apis-router-V5