Skip to content
Branch: master
Find file History
aibek-bird updated react native redux sample
* Bugfixes
* Added snapshot tests
* Thumbnail preview in chats
Latest commit fc3f084 Jun 20, 2019
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
ReactNativeWithSendBird updated react native redux sample Jun 20, 2019
README.md updated react native redux sample Jun 20, 2019

README.md

Sample JavaScript React-Native Redux

SendBird React-Native sample using SendBird SDK.

Prerequisite

Run the sample

  1. Install React Native CLI.

     npm install -g react-native-cli
    
  2. Install required packages.

     npm install
    
  3. (iOS only) Pod install.

     cd ios
     pod install
    
  4. (iOS only) Add library in XCode

  • Open XCode and load workspace
  • Right click to 'Libraries' > Add Files to "Project Name" > select node_modules/react-native/Libraries/PushNotificationIOS/RCTPushNotification.xcodeproj
  • Right click to 'Libraries' > Add Files to "Project Name" > select node_modules/react-native-gesture-handler/ios/RNGestureHandler.xcodeproj
  • Project Settings > Build Phases > Link Binary With Libraries > Add libRCTPushNotification.a
  • Project Settings > Build Phases > Link Binary With Libraries > Add libRNGestureHandler.a
  • Project Settings > Build Phases > Link Binary With Libraries > Add JavaScriptCore.framework
  1. Run the sample. Before starting, you should launch device amulator (or actual device) to run the sample in Android. This sample is not available for real device in iOS due to Apple Development Policy. In order to run React Native sample in real device, follow React Native official guide for your own setup.

     react-native run-android
     react-native run-ios
    

Troubleshooting

If you see an error like this: "Unable to load script from assets index.android.bundle."

  1. (in project directory) mkdir android/app/src/main/assets
  2. react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res

If you see an error like this: "Loading dependency graph...(node:45456) UnhandledPromiseRejectionWarning: Error: jest-haste-map: Haste module naming collision: Duplicate module name: react-native"

  1. Try to delete ios/Pods file
You can’t perform that action at this time.