The following document describes the installation steps for React Native versions prior to 0.60.x
yarn add react-native-facebook-account-kit
react-native link react-native-facebook-account-kit
Check the RNAccountKitPackage
is registered in your MainApplication.java
file. This should be done by react-native link
but sometimes it doesn't. You should see something like the following
@Override
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage(),
new RNAccountKitPackage() // <-- the package is registered
);
}
-
Undo changes in
ios
folder (which were made byreact-native-link
) in order to avoid duplicate compilationsgit checkout -- ios
-
Add
RNAccountKit
Pod to your Podfile (if you don't have a podfile follow these instructions)target 'MyApp' do ... + pod 'RNAccountKit', :path => '../node_modules/react-native-facebook-account-kit/ios' ... end
-
Run
pod install
in yourios
folder
-
Open your project with XCode
-
Open with Finder the
node_modules/react-native-facebook-account-kit/ios
folder -
Drag and drop
AccountKit.framework
andAccountKitStrings.bundle
from Finder to your project in XCode (IMPORTANT: unselect the "Copy items if needed" option) -
Select you app target on XCode and click the
Build Settings
tab. Go to theFramework Search Paths
section and add this new entry$(SRCROOT)/../node_modules/react-native-facebook-account-kit/ios
NOTE: We strongly recomend using cocoapods that's why on version 1.2.0 we removed the
AccountKit.framework
/AccountKitStrings.bundle
files from the project. If you don't want to use cocoapods you can still download the framework and the bundle from here and add it to your project by yourself.