简体   繁体   English

requireNativeComponent:在 UIManager 中找不到“RNSScreenStackHeaderConfig”

[英]requireNativeComponent: "RNSScreenStackHeaderConfig" was not found in the UIManager

How to fix this error requireNativeComponent: "RNSScreenStackHeaderConfig" was not found in the UIManager.如何修复此错误 requireNativeComponent: 在 UIManager 中找不到“RNSScreenStackHeaderConfig”。 in windows pc i have tried @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(null);在 windows pc 我试过 @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(null); } but it didnt work and also tried.\gradlew clean both are not working in my case than how to fix it> } 但它没有工作,也试过了。\gradlew clean 在我的情况下两者都不起作用,而不是如何修复它>

my package.json我的 package.json

{
  "name": "letschat",
  "version": "0.0.1",
  "private": true,
  "scripts": {
    "android": "react-native run-android",
    "ios": "react-native run-ios",
    "start": "react-native start",
    "test": "jest",
    "lint": "eslint ."
  },
  "dependencies": {
    "@react-navigation/bottom-tabs": "^6.3.3",
    "@react-navigation/native": "^6.0.12",
    "@react-navigation/native-stack": "^6.8.0",
    "react": "18.0.0",
    "react-native": "0.69.5",
    "react-native-safe-area-context": "^4.3.3",
    "react-native-screens": "^3.17.0",
    "socket.io-client": "^4.5.1"
  },
  "devDependencies": {
    "@babel/core": "^7.12.9",
    "@babel/runtime": "^7.12.5",
    "@react-native-community/eslint-config": "^2.0.0",
    "babel-jest": "^26.6.3",
    "eslint": "^7.32.0",
    "jest": "^26.6.3",
    "metro-react-native-babel-preset": "^0.70.3",
    "react-test-renderer": "18.0.0"
  },
  "jest": {
    "preset": "react-native"
  }
}

Kill Metro and clean gradle build (it might take a minute or two):杀死 Metro 并清理 gradle 构建(可能需要一两分钟):

cd android

.\gradlew clean

Start Metro and clear cache:启动 Metro 并清除缓存:

npm start --reset-cache

Recompile重新编译

npm run android

暂无
暂无

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

相关问题 requireNativeComponent:运行 android 应用程序时,在 UIManager 中找不到“RNSScreenStackHeaderConfig” - requireNativeComponent: "RNSScreenStackHeaderConfig" was not found in the UIManager when running android app 在 UIManager 中找不到 requireNativeComponent - requireNativeComponent was not found in UIManager 不变违规:requireNativeComponent:在 Android 的 UIManager 中找不到“RNSVGSvgViewAndroid” - Invariant Violation: requireNativeComponent: "RNSVGSvgViewAndroid" was not found in the UIManager in Android 不变违规:不变违规:requireNativeComponent:在 UIManager 中找不到“RNCSafeAreaView”。 - Invariant Violation: Invariant Violation: requireNativeComponent: "RNCSafeAreaView" was not found in the UIManager." React-Native-SVG 错误:不变违规:requireNativeComponent:在 UIManager 中找不到“RNSVGGroup” - React-Native-SVG Error: Invariant Violation: requireNativeComponent: "RNSVGGroup" was not found in the UIManager 在 UIManager 中找不到 RNCSafeAreaView - RNCSafeAreaView was not found in the UIManager 在 UIManager 中找不到“RNCSafeAreaView” - "RNCSafeAreaView" was not found in the UIManager 错误:在 UIManager 中找不到“ARTShape” - React native - Error : "ARTShape" was not found in the UIManager - React native 安装 React Native Map。 在 UIManager 中找不到 AIRMap - Installing React Native Map. AIRMap not found in UIManager 当我想使用 React Navigation 时出现错误,错误:requireNativeComponent:在 UIManger 中找不到“RNSScreen” - I get an error when I wanna use React Navigation, Error: requireNativeComponent: “RNSScreen” was not found in the UIManger
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM