简体   繁体   English

Flutter:使用原生启动画面更好吗?

[英]Flutter : Is using Native Splash Screen better?

I am using flutter_native_splash package.我正在使用flutter_native_splash package。 Which works fine.哪个工作正常。 But what is the difference between using the native splash and a flutter page?但是使用本机启动页面和 flutter 页面有什么区别? Is there any difference regarding performance?性能上有什么区别吗?

when the flutter app is opened for the first time, there will be white screen for few seconds before any page is displayed.首次打开 flutter 应用程序时,在显示任何页面之前会出现几秒钟的白屏。

to tackle that issue, flutter_native_splash can be used.为了解决这个问题,可以使用flutter_native_splash It builds a native splash screen and will be displayed for few seconds until the first UI is drawn in the flutter app.它构建了一个原生启动屏幕,并将显示几秒钟,直到在 flutter 应用程序中绘制第一个 UI。

the native splash screen can also be closed programatically if needed it until some async task is done.如果需要,本机启动画面也可以通过编程方式关闭,直到完成一些异步任务。

The flutter_native_splash displays the splash screen before the Flutter engine is finished loading. flutter_native_splash在 Flutter 引擎完成加载之前显示启动画面。 If you use a Flutter page for a splash screen, it will be loaded after the Flutter engine is finished loading and there will be a delay during which a blank white screen will be displayed.如果您使用 Flutter 页面作为启动画面,它将在 Flutter 引擎完成加载加载,并且在此期间会有延迟显示空白屏幕。

(Full disclosure - I maintain the flutter_native_splash package) (完全披露——我维护了 flutter_native_splash 包)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 android 设备 flutter 中的闪屏不是全屏。 尝试了一切。 使用 flutter_native_splash - Splash Screen not full screen in android device flutter. Tried everyting. Using flutter_native_splash 如何在 flutter 中使用 flutter_native_splash package 更改启动画面的时间? - How to change time for splash screen using flutter_native_splash package in flutter? flutter 中,如何去掉原生启动画面和主画面之间的默认淡入淡出过渡? (仅使用本机启动画面) - How to remove the default fade transition between the native splash screen and the home screen in flutter? (Using native splash screen only) 如何使用 Flutter_native_splash 在初始屏幕底部添加文本 - How to add text at bottom in splash screen using Flutter_native_splash 我在我的应用程序中使用颤振原生启动包作为启动屏幕 - I am using flutter native splash package for splash screen in my app flutter原生启动画面的使用方法 - How to use the flutter native splash screen Flutter中需要实现Native闪屏2秒 - Need to implement Native splash screen for 2 seconds in flutter 如何在 Flutter 中获取原生启动画面? - How to get Native Splash Screen in Flutter? 本机启动画面图像不适用于 flutter (Android) - Native splash screen image not working on flutter (Android) Flutter 全屏闪屏 Android (native) - Flutter full screen splash in Android (native)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM