【问题标题】:Adding React Native module doesn't add line to Podfile, but `pod install` installs it anyway添加 React Native 模块不会向 Podfile 添加行,但 `pod install` 会安装它
【发布时间】:2019-10-20 18:41:25
【问题描述】:

我添加了react-native-device-infonpm i react-native-device-info。我使用的是 React Native 0.61,所以我希望它会自动在我的 Podfile 中为 RNDeviceInfo 添加一行。我的 Podfile 没有改变,但是当我运行 pod install 时,它显示“正在安装 React Native Device Info”。我注意到这样做并没有将.xcodeproj.a 文件添加到Xcode。 谁能帮我理解发生了什么?

【问题讨论】:

    标签: xcode react-native cocoapods podfile react-native-device-info


    【解决方案1】:

    你必须去 node_modules 文件夹,找到 react-native-device-info 文件夹,最后一步是删除 RNDeviceInfo.podspec 文件。我建议您在删除之前复制 RNDeviceInfo.podspec 文件。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2023-03-20
      • 1970-01-01
      • 1970-01-01
      • 2018-08-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多