rn 0.61.5
桌面打开APP不起动,第一次可以打开 之后就点不开了,
打开as logcat 包如下错误
Attempt to invoke virtual method 'int android.view.WindowInsets.getSystemWindowInsetTop()' on a null object reference
并使用了SafeAreaView这个组件
解决方案:
- 这个组件需要在原生延时加载 或者 在app起动必经的几个页面不要使用这个组件(例如启动页)
- 参考是否使用react-native-safe-area-context v0.7.2版本以下版本 参考Issues https://github.com/th3rdwave/react-native-safe-area-context/issues/55