Skip to content

Commit e919e55

Browse files
committed
Fix the Cordova SDK documentation
1 parent 5972abc commit e919e55

File tree

2 files changed

+31
-9
lines changed

2 files changed

+31
-9
lines changed

fern/docs/pages/sdks/mobile/cordova/features.mdx

Lines changed: 27 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ You can select from the following methods to identify users within your applicat
2121
The anonymous identification method allows you to create an anonymous user with an optional user identifier, ensuring that no other data is stored or associated with the user.
2222

2323
```javascript
24-
DevRev.identifyAnonymousUser(successCallback, errorCallback)
24+
DevRev.identifyAnonymousUser(userID, successCallback, errorCallback)
2525
```
2626

2727
### Unverified identification
@@ -89,7 +89,7 @@ As a good practice, **your** app should retrieve the exchanged session token fro
8989
Pass the user identifier and the exchanged session token to the verified identification method:
9090

9191
```javascript
92-
DevRev.identifyVerifiedUser(identity, successCallback, errorCallback)
92+
DevRev.identifyVerifiedUser(userID, sessionToken, successCallback, errorCallback)
9393
```
9494

9595
### Update the user
@@ -112,6 +112,8 @@ You can log out the current user by using the following method:
112112
DevRev.logout(deviceID, successCallback, errorCallback)
113113
```
114114

115+
The user is logged out by clearing their credentials, as well as unregistering the device from receiving push notifications, and stopping the session recording.
116+
115117
### Identity model
116118

117119
The `Identity` interface is used to provide user, organization, and account information when identifying users or updating their details. This class is used primarily with the `identifyUnverifiedUser` and `updateUser` methods.
@@ -184,8 +186,6 @@ All properties in `AccountTraits` are optional.
184186
| `tier` | `string OR null` | The account's tier or plan level |
185187
| `customFields` | `{ [key: string]: any }` | Dictionary of custom fields configured in DevRev |
186188

187-
The user is logged out by clearing their credentials, as well as unregistering the device from receiving push notifications, and stopping the session recording.
188-
189189
## PLuG support chat
190190

191191
Once user identification is complete, you can start using the chat (conversations) dialog supported by our DevRev SDK. The support chat feature can be shown as a modal screen from the top-most screen.
@@ -262,6 +262,7 @@ The session recording feature includes the following methods to control the reco
262262
|`DevRev.stopRecording(successCallback, errorCallback)` | Ends the session recording and uploads it to the portal. |
263263
|`DevRev.pauseRecording(successCallback, errorCallback)` | Pauses the ongoing session recording. |
264264
|`DevRev.resumeRecording(successCallback, errorCallback)` | Resumes a paused session recording. |
265+
|`DevRev.processAllOnDemandSessions(successCallback, errorCallback)` | Manually triggers processing of all on-demand sessions. |
265266

266267
### Session properties
267268

@@ -316,7 +317,28 @@ DevRev.endTimer(name, properties, successCallback, errorCallback)
316317
The DevRev SDK offers automatic screen tracking to help you understand how users navigate through your app. Although view controllers are automatically tracked, you can manually track screens using the following method:
317318

318319
```javascript
319-
DevRev.trackScreenName(screenName, successCallback, errorCallback)
320+
DevRev.trackScreenName(name, successCallback, errorCallback)
321+
```
322+
323+
### Screen transition management (Android only)
324+
325+
The DevRev SDK allows tracking of screen transitions to understand the user navigation within your app.
326+
You can manually update the state using the following methods:
327+
328+
```javascript
329+
// Mark the transition as started.
330+
DevRev.setInScreenTransitioning(true)
331+
332+
// Mark the transition as ended.
333+
DevRev.setInScreenTransitioning(false)
334+
```
335+
336+
## Dynamic theme configuration
337+
338+
The DevRev SDK allows you to configure the theme dynamically based on the system appearance, or use the theme configured on the DevRev portal. By default, the theme will be dynamic and follow the system appearance.
339+
340+
```javascript
341+
DevRev.setPrefersSystemTheme(value, successCallback, errorCallback)
320342
```
321343

322344
## Push notifications

fern/docs/pages/sdks/mobile/cordova/migration-guide.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ This guide and chart should help facilitate the transition from the legacy UserE
88
|-|-|-|
99
| Installation | `cordova plugin add userexperior-cordova-plugin@<version>` | `cordova plugin add @devrev/sdk-cordova` |
1010
| Initialization | `UserExperior.startRecording(appID)` | `DevRev.configure(appID, successCallback, errorCallback)` |
11-
| User Identification | `UserExperior.setUserIdentifier(userIdentifier)` | `DevRev.identifyAnonymousUser(userID, successCallback, errorCallback)`<br /> `DevRev.identifyUnverifiedUser(identity, successCallback, errorCallback)`<br /> `DevRev.updateUser(identity, successCallback, errorCallback)`<br /> `DevRev.logout(deviceID, successCallback, errorCallback)` |
11+
| User Identification | `UserExperior.setUserIdentifier(userIdentifier)` | `DevRev.identifyAnonymousUser(userID, successCallback, errorCallback)`<br /> `DevRev.identifyUnverifiedUser(identity, successCallback, errorCallback)`<br /> `DevRev.identifyVerifiedUser(userID, sessionToken, successCallback, errorCallback)`<br /> `DevRev.updateUser(identity, successCallback, errorCallback)`<br /> `DevRev.logout(deviceID, successCallback, errorCallback)` |
1212
| Event Tracking | `UserExperior.logEvent(name)` | `DevRev.trackEvent(name, properties, successCallback, errorCallback)` |
1313
| Session Recording | `UserExperior.stopRecording()`<br />`UserExperior.pauseRecording()`<br />`UserExperior.resumeRecording()` | `DevRev.startRecording(successCallback, errorCallback)`<br />`DevRev.stopRecording(successCallback, errorCallback)`<br />`DevRev.pauseRecording(successCallback, errorCallback)`<br />`DevRev.resumeRecording(successCallback, errorCallback)` |
1414
| Opting-in or out | `UserExperior.optOut()`<br /> `UserExperior.optIn()`<br /> `UserExperior.getOptOutStatus()` | `DevRev.stopAllMonitoring(successCallback, errorCallback)`<br /> `DevRev.resumeAllMonitoring(successCallback, errorCallback)` |
15-
| Session Properties | `UserExperior.setUserProperties(userProperties)` | `DevRev.addSessionProperties(properties, successCallback, errorCallback)`<br />`DevRev.clearSessionProperties()` |
15+
| Session Properties | `UserExperior.setUserProperties(userProperties)` | `DevRev.addSessionProperties(properties, successCallback, errorCallback)`<br />`DevRev.clearSessionProperties(successCallback, errorCallback)` |
1616
| Masking Sensitive Data | `<input type="text" placeholder="Enter Username" name="username" required class="ue-mask">`<br />`<input type="text" placeholder="Enter Username" name="username" required class="ue-unmask">` | `<input type="text" placeholder="Enter Username" name="username" required class="devrev-mask">`<br />`<input type="text" placeholder="Enter Username" name="username" required class="devrev-unmask">` |
17-
| Timers | `UserExperior.startTimer(timerName, properties)`<br /> `UserExperior.endTimer(timerName, properties)` | `DevRev.startTimer(name, properties)`<br /> `DevRev.endTimer(name, properties)` |
18-
| PLuG support chat | Not supported. | `DevRev.showSupport(successCallback, errorCallback)`<br /> `DevRev.createSupportConversation(successCallback, errorCallback)`<br /> `DevRev.setShouldDismissModalsOnOpenLink(value, successCallback, errorCallback)`<br /> `DevRevSDK.setInAppLinkHandler(handler, successCallback, errorCallback)` |
17+
| Timers | `UserExperior.startTimer(timerName, properties)`<br /> `UserExperior.endTimer(timerName, properties)` | `DevRev.startTimer(name, properties, successCallback, errorCallback)`<br /> `DevRev.endTimer(name, properties, successCallback, errorCallback)` |
18+
| PLuG support chat | Not supported. | `DevRev.showSupport(successCallback, errorCallback)`<br /> `DevRev.createSupportConversation(isAnimated, successCallback, errorCallback)`<br /> `DevRev.setShouldDismissModalsOnOpenLink(value, successCallback, errorCallback)`<br /> `DevRev.setInAppLinkHandler(handler, successCallback, errorCallback)` |
1919
| Push Notifications | Not supported. | `DevRev.registerDeviceToken(deviceToken, deviceID, successCallback, errorCallback)`<br /> `DevRev.unregisterDevice(deviceID, successCallback, errorCallback)`<br />`DevRev.processPushNotification(payload, successCallback, errorCallback)` |

0 commit comments

Comments
 (0)