【发布时间】:2017-08-08 21:57:47
【问题描述】:
我正在使用 react native: 0.41.2、react: 15.4.2 和 cocoapods for firebase(https://github.com/evollu/react-native-fcm)。 我在构建代码时遇到问题。 'React/RCTEventEmitter.h', 'React/RCTBridgeModule.h', 'React/RCTViewManager.h', 'React/RCTDefines.h' 这些文件未找到错误在运行项目时抛出.
但是通过使用该文件名单击 ctrl,这些文件已经在我的项目中。 Image
podfile:
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
source 'https://github.com/CocoaPods/Specs.git'
target 'Inspector' do
# Uncomment the next line if you're using Swift or would like to use dynamic frameworks
# use_frameworks!
# Pods for Inspector
react_native_path = "../node_modules/react-native"
pod "React", :path => react_native_path, :subspecs => [
'Core',
'RCTActionSheet',
'RCTAnimation',
'RCTGeolocation',
'RCTImage',
'RCTLinkingIOS',
'RCTNetwork',
'RCTSettings',
'RCTText',
'RCTVibration',
'RCTWebSocket'
]
pod 'Firebase/Core'
pod 'Firebase/Messaging'
target 'Inspector-tvOSTests' do
inherit! :search_paths
pod 'Firebase/Messaging'
# Pods for testing
end
target 'InspectorTests' do
inherit! :search_paths
pod 'Firebase/Messaging'
# Pods for testing
end
end
【问题讨论】:
标签: ios xcode firebase react-native cocoapods