我通过flfl指令安装了react-native-fbsdk。 https://github.com/facebook/react-native-fbsdk
但是,我在AppDelegate.m
中收到错误'阵营/ RCTBundleURLProvider.h'找不到文件
#import "AppDelegate.h"
#import <React/RCTBundleURLProvider.h> <- Error here
#import <React/RCTRootView.h>
#import "RNFIRMessaging.h"
卸载react-native-fbsdk解决了这个问题所以显然这个库导致了这个问题。 我试过的东西是
所有这些都没有用。
我的package.json如下所示。 有什么线索吗?
{
"name": "BitcoinApp",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"dependencies": {
"axios": "0.16.2",
"moment": "2.18.1",
"native-base": "2.1.5",
"react": "16.0.0-alpha.12",
"react-base": "0.2.0",
"react-native": "0.45.1",
"react-native-app-intro": "1.1.5",
"react-native-fbsdk": "^0.6.0",
"react-native-fcm": "^7.5.1",
"react-native-firebase-analytics": "^3.0.2",
"react-native-gifted-form": "0.0.14",
"react-native-loading-spinner-overlay": "0.5.0",
"react-native-pathjs-charts": "0.0.29",
"react-native-scrollable-tab-view": "0.6.6",
"react-native-social-share": "^1.1.0",
"react-native-store": "0.4.1",
"react-navigation": "1.0.0-beta.11"
},
"devDependencies": {
"babel-jest": "20.0.3",
"babel-preset-react-native": "1.9.2",
"eslint-config-rallycoding": "^3.2.0",
"jest": "20.0.4",
"react-test-renderer": "16.0.0-alpha.12"
},
"jest": {
"preset": "react-native"
}
}
答案 0 :(得分:0)
解决。
卸载SDK并再次阅读后续说明。 https://developers.facebook.com/docs/ios/getting-started/
这一次,在&#34;步骤2:下载适用于iOS的Facebook SDK&#34;,将SDK放入&#34;〜/ Documents / FacebookSDK&#34;。
因此,导致此问题的原因是SDK目录不在&#34;〜/ Documents / FacebookSDK&#34;。