bug出现环境背景

使用Cocospod安装RN的时候,报错


bug分析

[!] Unable to satisfy the following requirements:


- `Yoga (= 0.44.0.React)` required by `React/Core (0.44.0)`


None of your spec sources contain a spec satisfying the dependency: `Yoga (= 0.44.0.React)`.


You have either:

 * out-of-date source repos which you can update with `pod repo update`.

 * mistyped the name or version.

 * not added the source repo that hosts the Podspec to your Podfile.


Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.



分析可知React/core 依赖于Yoga所以咱应该使用pod添加Yoga,那么Yaga在什么目录下呢。

如果你已经使用nmp下载RN的Modules,你可以搜到Yoga的目录

- `Yoga (= 0.44.0.React)` required by `React/Core (0.44.0)`

bug解决办法


安装依赖包yoga
path为上图中路径
pod 'Yoga',  :path => ‘../node_modules/react-native/ReactCommon/yoga'



相关文章:

  • 2021-10-28
  • 2021-11-23
  • 2021-10-28
  • 2021-07-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-05-06
  • 2022-01-08
  • 2021-12-15
  • 2021-09-26
  • 2021-10-29
  • 2021-03-15
相关资源
相似解决方案