README
KakaoSDK for React Native
Getting started
$ npm install react-native-ccs-kakaosdk --save
Mostly automatic installation
$ react-native link react-native-ccs-kakaosdk
Manual installation
iOS (without CocoaPod)
- In XCode, in the project navigator, right click
Libraries➜Add Files to [your project's name] - Go to
node_modules➜react-native-ccs-kakaosdkand addRNCcsKakaosdk.xcodeproj - In XCode, in the project navigator, select your project. Add
libRNCcsKakaosdk.ato your project'sBuild Phases➜Link Binary With Libraries - Run your project (
Cmd+R)<
iOS (with CocoaPod)
- In XCode, in the project navigator, right click
Libraries➜Add Files to [your project's name] - Go to
node_modules➜react-native-ccs-kakaosdkand addRNCcsKakaosdk.xcodeproj - In XCode, in the project navigator, select your project. Add
libRNCcsKakaosdk.ato your project'sBuild Phases➜Link Binary With Libraries - Run your project (
Cmd+R)<
Android
- Open up
android/app/src/main/java/[...]/MainActivity.java
- Add
import com.reactlibrary.RNCcsKakaosdkPackage;to the imports at the top of the file - Add
new RNCcsKakaosdkPackage()to the list returned by thegetPackages()method
- Append the following lines to
android/settings.gradle:include ':react-native-ccs-kakaosdk' project(':react-native-ccs-kakaosdk').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-ccs-kakaosdk/android') - Insert the following lines inside the dependencies block in
android/app/build.gradle:compile project(':react-native-ccs-kakaosdk')
Initalizing project
iOS
Android
Usage
import KakaoSDK from 'react-native-ccs-kakaosdk';
// TODO: What to do with the module?
KakaoSDK.login().then().catch();