Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,40 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).


## [2.3.1] - 2026-04-27

### Fixed
- Improved session recording stability and reduced resource usage on both platforms.
- Fixed multiple crashes and ANRs during session recording and app termination.
- Fixed incorrect session engagement time calculations on Android.

## [2.3.0] - 2026-02-24

### Added
- Feature configuration for screen capture, auto-start recording, plug chat theme, and remote config (fresh vs cached/lazy fetch).
- Support for React Native versions >= 0.79.

### Changed
- Improved frame capture disabled session replays experience.
- [iOS] Session upload now enforces minimum visit duration before uploading.

### Fixed
- Fixed a few memory leaks and crashes.

## [2.2.6] - 2026-02-16

### Fixed
- Fixed an issue with session recordings on QR scan screens on Android.

## [2.2.5] - 2026-02-02

### Changed
- Modernized legacy components and aligned for better performance.

### Removed
- Removed deprecated and non-public iOS APIs.

## [2.2.4] - 2026-01-29

### Changed
Expand Down
85 changes: 82 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ DevRev SDK, used for integrating DevRev services into your React Native and Expo
- [Installation](#installation)
- [Expo](#expo)
- [Set up the DevRev SDK](#set-up-the-devrev-sdk)
- [Update the feature configuration](#update-the-feature-configuration)
- [Feature configuration reference](#feature-configuration-reference)
- [Support widget theme options](#support-widget-theme-options)
- [Features](#features)
- [Identification](#identification)
- [Identify an unverified user](#identify-an-unverified-user)
Expand Down Expand Up @@ -60,7 +63,6 @@ DevRev SDK, used for integrating DevRev services into your React Native and Expo
- For Expo apps, Expo 50.0.0 or later.
- Android: minimum API level 24.
- iOS: minimum deployment target 15.1.
- (Recommended) An SSH key configured locally and registered with [GitHub](https://docs.github.com/en/github/authenticating-to-github/connecting-to-github-with-ssh).

### Installation

Expand Down Expand Up @@ -100,12 +102,89 @@ npm install @devrev/sdk-react-native
> [!WARNING]
> The DevRev SDK must be configured before you can use any of its features.

The SDK becomes ready for use once the following configuration method is executed.
The SDK becomes ready for use once the configuration API is executed.

```typescript
DevRev.configure(appID: string)
DevRev.configure(appID)
```

To provide a feature configuration during setup, call the overload that accepts it:

```typescript
DevRev.configure(appID, featureConfiguration)
```

For default behavior, call the simpler form:

```typescript
DevRev.configure('abcdefg12345')
```

To customize behavior such as frame capture, auto-start recording, or theme preferences, pass a full `FeatureConfiguration` object:

```typescript
DevRev.configure('abcdefg12345', {
enableFrameCapture: false,
autoStartRecording: false,
prefersDialogMode: false,
alwaysUseRemoteConfig: true,
supportWidgetTheme: {
prefersSystemTheme: true,
},
});
```

#### Update the feature configuration

You can adjust the feature configuration without reconfiguring the SDK. Pass a **full** `FeatureConfiguration` object (all properties are required):

```typescript
DevRev.updateFeatureConfiguration({
enableFrameCapture: true,
autoStartRecording: true,
prefersDialogMode: false,
alwaysUseRemoteConfig: true,
supportWidgetTheme: {
prefersSystemTheme: true,
},
});
```

#### Feature configuration reference

`FeatureConfiguration` controls how the SDK behaves both during initial setup and when calling `DevRev.updateFeatureConfiguration(...)`. All properties are required when providing a feature configuration.

| Property | Type | Default | Description |
|----------|------|---------|-------------|
| `enableFrameCapture` | `boolean` | `true` | Enables the screen capture pipeline used by session replay. |
| `autoStartRecording` | `boolean` | `true` | Automatically starts recording after the SDK finishes remote configuration. |
| `prefersDialogMode` | `boolean` | `false` | Prefer dialog mode for the support UI (Android only). |
| `alwaysUseRemoteConfig` | `boolean` | `true` | Always use remote config. |
| `supportWidgetTheme` | `SupportWidgetTheme` | — | Controls the appearance of the in-app support widget, including dynamic theme behavior. |

##### Support widget theme options

`SupportWidgetTheme` lets you fine-tune the support UI. Use the `supportWidgetTheme` property inside your feature configuration.

```typescript
const customTheme = {
prefersSystemTheme: false,
primaryTextColor: '#1F2933',
accentColor: '#F97316',
spacing: {
bottom: '20px',
side: '16px',
},
};
```

| Property | Type | Default | Description |
|----------|------|---------|-------------|
| `prefersSystemTheme` | `boolean` | `true` | Follows the device appearance when `true`; otherwise uses your custom colors. |
| `primaryTextColor` | `string?` | — | Hex color string (e.g. `'#000000'`, `'#1F2933'`) for primary text in the support widget. |
| `accentColor` | `string?` | — | Hex color string (e.g. `'#F97316'`, `'#FF0000'`) applied to buttons and highlights. |
| `spacing` | `{ [key: string]: string }?` | — | CSS-like spacing overrides (`bottom` and `side` keys are recognized). |

## Features

### Identification
Expand Down
Binary file added devrev-sdk-react-native-2.3.1.tgz
Binary file not shown.
2 changes: 2 additions & 0 deletions sample/expo/PushNotificationsService.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ Notifications.setNotificationHandler({
shouldShowAlert: true,
shouldPlaySound: true,
shouldSetBadge: true,
shouldShowBanner: true,
shouldShowList: true,
};
},
});
Expand Down
18 changes: 16 additions & 2 deletions sample/expo/app.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,19 @@
[
"../../app.plugin.js"
],
[
"expo-image-picker",
{
"photosPermission": "App needs access to your photos."
}
],
[
"expo-camera",
{
"cameraPermission": "Allow $(PRODUCT_NAME) to access your camera",
"recordAudioAndroid": false
}
],
[
"expo-notifications",
{
Expand All @@ -63,12 +76,13 @@
"use_modular_headers!": true
}
}
]
],
"expo-asset"
],
"extra": {
"eas": {
"projectId": "501ce10b-b735-428d-8429-6616662accd7"
}
}
}
}
}
13 changes: 10 additions & 3 deletions sample/expo/components/TouchableOpacityButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,30 @@ import {
StyleSheet,
type TextStyle,
type ViewStyle,
StyleProp,
} from 'react-native';

interface TouchableOpacityProps {
onPress: () => void;
buttonText: string;
buttonStyle?: ViewStyle;
textStyle?: TextStyle;
buttonStyle?: StyleProp<ViewStyle>;
textStyle?: StyleProp<TextStyle>;
disabled?: boolean;
}

const TouchableOpacityButton: React.FC<TouchableOpacityProps> = ({
onPress,
buttonText,
buttonStyle,
textStyle,
disabled = false,
}) => {
return (
<TouchableOpacity style={[styles.button, buttonStyle]} onPress={onPress}>
<TouchableOpacity
style={[styles.button, buttonStyle]}
onPress={onPress}
disabled={disabled}
>
<Text style={[styles.buttonText, textStyle]}>{buttonText}</Text>
</TouchableOpacity>
);
Expand Down
14 changes: 14 additions & 0 deletions sample/expo/navigator/Navigator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import DelayedScreen from '../screens/DelayScreen';
import WebViewScreen from '../screens/WebViewScreen';
import FlatListScreen from '../screens/FlatListScreen';
import { TouchableOpacity, StyleSheet, Text } from 'react-native';
import CameraScreen from '../screens/CameraScreen';
import ImageUploadScreen from '../screens/ImageUpload';

export type RootStackParamList = {
Home: undefined;
Expand All @@ -19,6 +21,8 @@ export type RootStackParamList = {
DelayScreen: undefined;
WebViewScreen: undefined;
FlatListScreen: undefined;
ImageUploadScreen: undefined;
CameraScreen: undefined;
};

const Stack = createStackNavigator<RootStackParamList>();
Expand Down Expand Up @@ -60,6 +64,16 @@ const screens = [
component: FlatListScreen,
title: 'Large Scrollable List',
},
{
name: 'CameraScreen',
component: CameraScreen,
title: 'Camera',
},
{
name: 'ImageUploadScreen',
component: ImageUploadScreen,
title: 'Gallery Upload',
},
] as const;

const createScreen = (
Expand Down
6 changes: 5 additions & 1 deletion sample/expo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,19 @@
"@react-navigation/native-stack": "^7.3.14",
"@react-navigation/stack": "^7.1.2",
"expo": "^53.0.0",
"expo-asset": "~11.1.7",
"expo-build-properties": "~0.14.8",
"expo-camera": "~16.1.11",
"expo-file-system": "~18.1.11",
"expo-firebase-messaging": "^2.0.0",
"expo-image-picker": "~16.1.4",
"expo-notifications": "~0.31.4",
"expo-system-ui": "~5.0.11",
"react": "19.0.0",
"react-native": "0.79.5",
"react-native-device-info": "^14.0.2",
"react-native-gesture-handler": "~2.24.0",
"react-native-safe-area-context": "5.4.0",
"react-native-safe-area-context": "^5.6.2",
"react-native-screens": "~4.11.1",
"react-native-webview": "13.13.5"
},
Expand Down
Loading
Loading