Skip to content

ISS-183379: Update hybrid mobile SDK docs with sample app section(React Native, Expo, Cordova) #264

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jun 18, 2025
Merged
39 changes: 37 additions & 2 deletions fern/docs/pages/sdks/mobile/cordova/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ This guide helps you integrate the DevRev SDK into your Cordova app.
## Requirements

- Cordova CLI 10.0.0 or higher.
- A minimum deployment target of Android 5.0 (API level 21) or iOS 11.
- Minimum deployment target Android SDK 24 or iOS 15.

## Installation

To install the DevRev SDK, run the following command:

```sh
cordova plugin add devrev-cordova-plugin
cordova plugin add devrev/sdk-cordova
```

## Set up the DevRev SDK
Expand All @@ -30,3 +30,38 @@ The SDK will be ready for use once you execute the following configuration metho
```javascript
DevRev.configure(appID, successCallback, errorCallback)
```

## Sample app
A sample app with use cases for the DevRev Cordova plugin is provided as part of our [public repository](https://github.com/devrev/devrev-sdk-cordova). To set up and run the sample app:

```sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not clear what the relationship between these steps and the Android/iOS-specific steps below are.

Tabs are often used for platform-specific information. https://buildwithfern.com/learn/docs/content/components/tabs

cd sample
npm install
cordova platform add android
cordova platform add ios
```

<Tabs>
<Tab title="Android">
```sh
cordova run android
```
OR open `platforms/android` in Android Studio and run the app.
</Tab>
<Tab title="iOS">
1. Open `platforms/ios/Podfile` and ensure it contains:
```ruby
platform :ios, '15.0'
```
2. Install dependencies:
```sh
cd platforms/ios
pod install
```
3. Run the app:
```sh
cordova run ios
```
OR open `DevRevSDKSample.xcworkspace` in Xcode and run the app.
</Tab>
</Tabs>
30 changes: 30 additions & 0 deletions fern/docs/pages/sdks/mobile/react-native/quickstart-expo.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,33 @@ The SDK will be ready for use once you execute the following configuration metho
```typescript
DevRev.configure(appID: string)
```

## Sample app
A sample app with use cases for the DevRev Expo plugin has been provided as a part of our [public repository](https://github.com/devrev/devrev-sdk-expo). To set up and run the sample app:

1. Go to sample directory:
```sh
cd sample
```

2. Install dependencies:
```sh
yarn install
```

3. Run clean and prebuild:
```sh
npx expo prebuild --clean
```

4. Run the app On Android:
```sh
npx expo run:android
```
OR open `android` in Android Studio and run the app.

5. Run the app On iOS:
```sh
npx expo run:ios
```
OR open `ios/DevRevSDKSample.xcworkspace` in Xcode and run the app.
25 changes: 25 additions & 0 deletions fern/docs/pages/sdks/mobile/react-native/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,28 @@ The SDK will be ready for use once you execute the following configuration metho
```typescript
DevRev.configure(appID: string)
```

## Sample app
A sample app with use cases for the DevRev React Native plugin has been provided as a part of our [public repository](https://github.com/devrev/devrev-sdk-react-native). To set up and run the sample app:

1. Go to the sample directory:
```sh
cd sample
```

2. Install dependencies:
```sh
yarn install
```

3. For iOS, run:
```sh
cd ios
pod install
```

4. Run the app on Android or iOS using:
```sh
npx react-native start
```
Or open `android` directory in Android Studio or `ios/DevRevSDKSample.xcworkspace` in Xcode and run the app from there.
Loading