【发布时间】:2020-09-03 11:07:42
【问题描述】:
我目前正在集成来自供应商的私有库,他们提到需要在 Podfile 中添加 use_framework!。显然我从他们那里发现,框架是用 Objective-C 编写的,如果是这样.. 为什么需要use_framework!?我以为this is the reason why 我们使用use_framework!
use_frameworks 告诉 CocoaPods 你想使用框架而不是静态库。由于 Swift 不支持静态库,因此您必须使用框架。
目前我在AppDelegate.h 中面临这个构建时间问题'React/RCTBridgeDelegate.h' not found
附加信息,
- 我的项目在 React Native Firebase v6 上运行,因此我添加了
# $RNFirebaseAsStaticFramework = true来处理use_framework!的情况。 Read more about this here。 - 如果我不附加
use_framework!,我会收到以下错误
没有找到框架helloFramework
我的问题,为什么我在使用 use_frameworks! 时会遇到这个问题?处理这个问题的正确方法是什么?
更新:
- 在React Native Github 创建问题
【问题讨论】:
标签: ios swift react-native ios-frameworks podfile