Code Monkey home page Code Monkey logo

react-native-freshchat's Introduction



React Native Freshchat

Overview

  1. Installation
  2. Setup
  3. Running

1. Installation

Clone react native freshchat

git clone https://github.com/fachrinfl/react-native-freshchat.git
cd react-native-freshchat

2. Setup

Before run the project setup the library

  1. Download library in react-native-freshchat-sdk
  2. Extract react-native-freshchat-sdk and place it inside node_module folder in your project
  3. Add "react-native-freshchat-sdk": "^0.4.0" under dependencies in project package.json
  4. Run react-native link on you project root directory

Add Manually react-native-freshchat-sdk in Android

  • in android/settings.gradle
...
include ':react-native-freshchat-sdk'
project(':react-native-freshchat-sdk').projectDir = new File(settingsDir, '../node_modules/react-native-freshchat-sdk/android')
  • in android/app/build.gradle add:
dependencies {
    ...
    compile project(':react-native-freshchat-sdk')
}
  • and finally, in android/src/main/java/com/{YOUR_APP_NAME}/MainApplication.java
//...
import com.freshchat.consumer.sdk.react.RNFreshchatSdkPackage; // <--- This!
//...
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
    new MainReactPackage(),
    new RNFreshchatSdkPackage() // <---- and This!
  );
}

3. Running

react-native run-android

react-native-freshchat's People

Contributors

fachrinfl avatar

Stargazers

 avatar

Watchers

 avatar

react-native-freshchat's Issues

Error on install - No podspec found for `FreshchatSDK`

I'm trying to integrate freshchat on my react native project, but I'm getting this error:

Fetching podspec for `FreshchatSDK` from `../node_modules/react-native-freshchat-sdk/ios/FreshchatSDK.podspec`
[!] No podspec found for `FreshchatSDK` in `../node_modules/react-native-freshchat-sdk/ios/FreshchatSDK.podspec`

My RN version is 0.59

RN app opens even though the app is killed

Currently i'm having issues on the app automatically opens when user has opened the Freshchat support once, here are the things i tried to prevent but still failed:

  • freshchatNotificationConfig.overrideNotificationClickListener = true
    freshchatNotificationConfig.activityToLaunchOnFinish = "" (I also tried setting to null but the results are same)
    The react native app still opens when Freshchat support responded his/her chat

are there other setup i'm missing here for notifications?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.