@ada-support/react-native-sdk
v3.2.5
Published
The Ada ReactNative is a small framework that is used to embed your Ada Chat bot into your ReactNative application.
Downloads
19,471
Readme
Ada React Native SDK
Go here for client-facing docs.
Prerequisites
You will need to have the below installed in order to run/compile the code
- Java JDK - 17.x.x
- Java - 8
- XCode - Latest (get this from the App Store)
- If you installed xCode command line tools before xCode you may need to run
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
- If you installed xCode command line tools before xCode you may need to run
- Android Studio - Latest
- Node 18.x.x
- Ensure you download an iOS and/or an Android simulator in xCode/Android Studio and have them running.
Add the following to your PATH in bash (.profile) or zsh (.zshrc)
export ANDROID_HOME="/Users/<your mac user folder here>/Library/Android/sdk"
PATH="$PATH:${ANDROID_HOME}/platform-tools/"
Setting up your local environment (first run)
- cd into the
sample
directory:cd sample
- Install
node_modules
via yarn:yarn
- cd into the
ios
directory and runbundle install
. This installs the Bundler - Install needed Cocoapods via the Bundler:
bundle exec pod install
- Run either
yarn run ios
oryarn run android
to make sure everything is working
Local Development
If you want to make changes to the actual NPM module and test them - follow the below steps for iOS or Android
Local development of the NPM Module for Android
- To run the application on a simulated Android device, open Android Studio and start an AVD preferably one running Android 11 (API 30)
- In a terminal navigate to the
sample
folder, runyarn run android:with-install
to install all packages and install the module locally. It with automatically start up the simulator and install the app for you.
Local development of the NPM Module for iOS
- In a terminal navigate to the
sample
folder and runyarn install
- In another terminal, navigate to
sample/ios
and runbundle exec pod install
- Once finished, run
yarn run ios:with-install
. It with automatically start up the simulator and install the app for you.
Note
If you are having problems with yarn install
make sure you're on Node 18.x.x
Deploying to production
Update the version number in the package.json file by incrementing the version value by 1 on the least significant value (eg. if version is 0.0.1, update it to 0.0.2)
Get your PR reviewed and then squash and merge it to
master
. Merging your PR will automatically trigger the deploy to npm