在 RCTBridgeModule.h 中找不到 React/RCTDefines.h 文件

洪开发商

我正在使用Expo,我分开expo eject用于模块使用。

pod install在iOS文件中尝试过这是工作。

Pod安装完成!Pod 文件中有 51 个依赖项,总共安装了 63 个 Pod。

但是当Xcode打开并build and run按下按钮时发生错误

错误图像 在此处输入图片说明 在此处输入图片说明 在此处输入图片说明

包.json:

{
  "name": "testgame",
  "version": "0.1.0",
  "private": true,
  "devDependencies": {
    "babel-cli": "6.26.0",
    "babel-plugin-module-resolver": "^3.1.1",
    "babel-preset-es2015": "6.24.1",
    "jest-expo": "27.0.0",
    "react-native-scripts": "1.14.0",
    "react-test-renderer": "16.3.1"
  },
  "main": "./node_modules/react-native-scripts/build/bin/crna-entry.js",
  "scripts": {
    "start": "react-native-scripts start",
    "eject": "react-native-scripts eject",
    "android": "react-native-scripts android",
    "ios": "react-native-scripts ios",
    "test": "jest"
  },
  "jest": {
    "preset": "jest-expo"
  },
  "dependencies": {
    "@expo/vector-icons": "^8.1.0",
    "bignumber.js": "^8.1.1",
    "crypto-browserify": "^3.12.0",
    "eth-lightwallet": "^3.0.1",
    "ethereumjs-tx": "^1.3.7",
    "ethereumjs-util": "^6.0.0",
    "ethereumjs-wallet-react-native": "^0.6.7",
    "expo": "^30.0.0",
    "expokit": "^1.8.0",
    "formik": "^1.3.2",
    "js-sha3": "^0.8.0",
    "native-base": "^2.8.2",
    "node-libs-browser": "2.1.0",
    "react": "16.3.1",
    "react-native": "https://github.com/expo/react-native/archive/sdk-30.0.0.tar.gz",
    "react-native-confirmation-code-input": "^1.0.4",
    "react-native-fast-crypto": "^1.8.1",
    "react-native-fetch-blob": "git+https://github.com/HCL-HO/react-native-fetch-blob-expo.git",
    "react-native-fs": "^2.13.3",
    "react-native-keychain": "^3.1.2",
    "react-native-pin-view": "^2.2.1",
    "react-native-secure-randombytes": "^3.0.0",
    "react-native-touch-id": "^4.4.1",
    "react-navigation": "3.0.4",
    "web3": "1.0.0-beta.34",
    "yup": "^0.26.6"
  }
}

Xcode 版本:10.2.1

我以前从未使用Xcode过,所以我是初学者。请详细说明。如果您能用屏幕截图解释一下,我将不胜感激。

洪开发商

podsec自己做了一个并解决了它。

这不在官方文档中,需要模块开发人员提供基本解决方案。

此解决方案创建了很多Warning. 代码没有任何问题。

  1. react-native-secure-randombytes从标题搜索路径中删除路径
  2. Unlinkreact-native-secure-randombytes模块 - react-native unlink react-native-secure-randombytes
  3. 从此链接添加了 react-native-secure-randombytes.podspec
  4. 将下一个代码添加到 pod 文件中:

    pod 'react-native-secure-randombytes', :path => '../node_modules/react-native-secure-randombytes'

  5. 做“吊舱安装”

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章