Skip to content

Commit ca05e8d

Browse files
author
TomWq
committed
更新文档内容
1 parent 44344fb commit ca05e8d

File tree

2 files changed

+4
-16
lines changed

2 files changed

+4
-16
lines changed

README.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ import UIKit
111111
import React
112112
import React_RCTAppDelegate
113113
import ReactAppDependencyProvider
114-
import react_native_splash_screen
114+
import react_native_splash_screen // <--- 添加react_native_splash_screen
115115

116116
@main
117117
class AppDelegate: UIResponder, UIApplicationDelegate {
@@ -136,7 +136,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
136136
in: window,
137137
launchOptions: launchOptions
138138
)
139-
RNSplashScreen.show()
139+
RNSplashScreen.show() // <--- 确保在 React Native 启动后调用
140140
return true
141141
}
142142
}
@@ -167,12 +167,6 @@ class ReactNativeDelegate: RCTDefaultReactNativeFactoryDelegate {
167167

168168
Android 12+ always has a system-level splash phase. This is platform behavior. This library controls your in-app splash show/hide behavior.
169169

170-
### `Cannot read property 'hide' of null`
171-
172-
This usually means the native module did not load correctly:
173-
174-
- Ensure React Native version is `>= 0.84.0`
175-
- Reinstall dependencies and rebuild the app
176170

177171
## Legacy
178172

README.zh.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ import UIKit
111111
import React
112112
import React_RCTAppDelegate
113113
import ReactAppDependencyProvider
114-
import react_native_splash_screen
114+
import react_native_splash_screen // <--- 添加react_native_splash_screen
115115

116116
@main
117117
class AppDelegate: UIResponder, UIApplicationDelegate {
@@ -136,7 +136,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
136136
in: window,
137137
launchOptions: launchOptions
138138
)
139-
RNSplashScreen.show()
139+
RNSplashScreen.show() // <--- 确保在 React Native 启动后调用
140140
return true
141141
}
142142
}
@@ -167,12 +167,6 @@ class ReactNativeDelegate: RCTDefaultReactNativeFactoryDelegate {
167167

168168
Android 12+ 存在系统级启动阶段,这是平台行为。本库控制的是应用内可控的启动页显示/隐藏。
169169

170-
### `Cannot read property 'hide' of null`
171-
172-
通常是原生模块没有正确加载:
173-
174-
- 确认 React Native 版本满足 `>= 0.84.0`
175-
- 重新安装依赖并重新编译 App
176170

177171
## Legacy 说明
178172

0 commit comments

Comments
 (0)