当前位置:   article > 正文

flutter 设置启屏页 flutter_native_splash 坑记录

flutter 设置启屏页 flutter_native_splash 坑记录

flutter_native_splash | Flutter packageCustomize Flutter's default white native splash screen with background color and splash image. Supports dark mode, full screen, and more.icon-default.png?t=N7T8https://pub.dev/packages/flutter_native_splash

发现一直白屏 

原因是 代码中 下面3行没有加 

runApp 调用之前 

WidgetsBinding widgetsBinding = WidgetsFlutterBinding.ensureInitialized();

FlutterNativeSplash.preserve(widgetsBinding: widgetsBinding);

FlutterNativeSplash.remove();

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/不正经/article/detail/494002
推荐阅读
相关标签
  

闽ICP备14008679号