TypeError: undefined is not an object (evaluating '_expoModulesCore.NativeModulesProxy.ExpoSplashScreen')
TypeError: undefined is not an object (evaluating '_expoModulesCore.NativeModulesProxy.ExpoSplashScreen')
我在 React Native 中遇到了这个问题。一切正常,直到我决定重新运行项目 yarn install
这里是完整的错误
TypeError: undefined is not an object (evaluating '_expoModulesCore.NativeModulesProxy.ExpoSplashScreen')
at node_modules\react-native\Libraries\LogBox\LogBox.js:148:8 in registerError
at node_modules\react-native\Libraries\LogBox\LogBox.js:59:8 in errorImpl
at node_modules\react-native\Libraries\LogBox\LogBox.js:33:4 in console.error
at node_modules\expo\build\environment\react-native-logs.fx.js:27:4 in error
at node_modules\react-native\Libraries\Core\ExceptionsManager.js:104:6 in reportException
at node_modules\react-native\Libraries\Core\ExceptionsManager.js:171:19 in handleException
at node_modules\react-native\Libraries\Core\setUpErrorHandling.js:24:6 in handleError
at node_modules\expo-error-recovery\build\ErrorRecovery.fx.js:12:21 in ErrorUtils.setGlobalHandler$argument_0
at node_modules\regenerator-runtime\runtime.js:63:36 in tryCatch
at node_modules\regenerator-runtime\runtime.js:294:29 in invoke
at node_modules\regenerator-runtime\runtime.js:63:36 in tryCatch
at node_modules\regenerator-runtime\runtime.js:155:27 in invoke
at node_modules\regenerator-runtime\runtime.js:165:18 in PromiseImpl.resolve.then$argument_0
at node_modules\react-native\node_modules\promise\setimmediate\core.js:37:13 in tryCallOne
at node_modules\react-native\node_modules\promise\setimmediate\core.js:123:24 in setImmediate$argument_0
at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:130:14 in _callTimer
at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:181:14 in _callImmediatesPass
at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:441:30 in callImmediates
at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:387:6 in __callImmediates
at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:135:6 in __guard$argument_0
at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:364:10 in __guard
at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:134:4 in flushedQueue
我已经尝试更新 expo-cli、expo-splash-screen 和缓存清除命令 expo r -c
如果有人可以提供帮助,请告诉我。
你可以显示日志的警告信息吗?因为我有同样的问题并解决了。
日志:
- expo-app-loading - 预期版本:1.1.2 - 实际安装版本:1.3.0
- react-native-screens - 预期版本:~3.4.0 - 实际安装版本:3.10.1
我在我的包中使用了 1.1.2 和 3.4.0 版本:
“react-native-screens”:“^3.4.0”到“react-native-screens”:“3.4.0”
“expo-app-loading”:“^1.1.2”到“expo-app-loading”:“1.1.2”
删除您的 node_modules、yarn.lock 和包裹-lock.json
Yarn 安装或 npm 安装
为我解决。
我遇到了 expo-web-browser 的问题。因此,只需在终端上使用以下命令清除缓存即可。您将不会再看到上述错误:
expo r -c
我在 React Native 中遇到了这个问题。一切正常,直到我决定重新运行项目 yarn install
这里是完整的错误
TypeError: undefined is not an object (evaluating '_expoModulesCore.NativeModulesProxy.ExpoSplashScreen') at node_modules\react-native\Libraries\LogBox\LogBox.js:148:8 in registerError at node_modules\react-native\Libraries\LogBox\LogBox.js:59:8 in errorImpl at node_modules\react-native\Libraries\LogBox\LogBox.js:33:4 in console.error at node_modules\expo\build\environment\react-native-logs.fx.js:27:4 in error at node_modules\react-native\Libraries\Core\ExceptionsManager.js:104:6 in reportException at node_modules\react-native\Libraries\Core\ExceptionsManager.js:171:19 in handleException at node_modules\react-native\Libraries\Core\setUpErrorHandling.js:24:6 in handleError at node_modules\expo-error-recovery\build\ErrorRecovery.fx.js:12:21 in ErrorUtils.setGlobalHandler$argument_0 at node_modules\regenerator-runtime\runtime.js:63:36 in tryCatch at node_modules\regenerator-runtime\runtime.js:294:29 in invoke at node_modules\regenerator-runtime\runtime.js:63:36 in tryCatch at node_modules\regenerator-runtime\runtime.js:155:27 in invoke at node_modules\regenerator-runtime\runtime.js:165:18 in PromiseImpl.resolve.then$argument_0 at node_modules\react-native\node_modules\promise\setimmediate\core.js:37:13 in tryCallOne at node_modules\react-native\node_modules\promise\setimmediate\core.js:123:24 in setImmediate$argument_0 at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:130:14 in _callTimer at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:181:14 in _callImmediatesPass at node_modules\react-native\Libraries\Core\Timers\JSTimers.js:441:30 in callImmediates at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:387:6 in __callImmediates at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:135:6 in __guard$argument_0 at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:364:10 in __guard at node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:134:4 in flushedQueue
我已经尝试更新 expo-cli、expo-splash-screen 和缓存清除命令 expo r -c
如果有人可以提供帮助,请告诉我。
你可以显示日志的警告信息吗?因为我有同样的问题并解决了。
日志:
- expo-app-loading - 预期版本:1.1.2 - 实际安装版本:1.3.0
- react-native-screens - 预期版本:~3.4.0 - 实际安装版本:3.10.1
我在我的包中使用了 1.1.2 和 3.4.0 版本: “react-native-screens”:“^3.4.0”到“react-native-screens”:“3.4.0” “expo-app-loading”:“^1.1.2”到“expo-app-loading”:“1.1.2”
删除您的 node_modules、yarn.lock 和包裹-lock.json
Yarn 安装或 npm 安装
为我解决。
我遇到了 expo-web-browser 的问题。因此,只需在终端上使用以下命令清除缓存即可。您将不会再看到上述错误:
expo r -c