react-native-appsflyer
Advanced tools
Comparing version 1.0.12 to 1.1.1
23
index.js
@@ -42,8 +42,25 @@ | ||
/** | ||
* For Android only (Google API). iOS uses 'didRegisterForRemoteNotificationsWithDeviceToken' in AppDelegate.m | ||
Deprecated | ||
*/ | ||
appsFlyer.setGCMProjectNumber = (gcmProjectNumber, successC, errorC) => { | ||
return RNAppsFlyer.setGCMProjectNumber(gcmProjectNumber, successC, errorC); | ||
}; | ||
/** | ||
* For Android only (GCM). iOS uses 'didRegisterForRemoteNotificationsWithDeviceToken' in AppDelegate.m | ||
*/ | ||
appsFlyer.setGCMProjectID = (gcmProjectId, successC, errorC) => { | ||
return RNAppsFlyer.setGCMProjectID(gcmProjectId, successC, errorC); | ||
appsFlyer.enableUninstallTracking = (gcmProjectNumber, successC) => { | ||
return RNAppsFlyer.enableUninstallTracking(gcmProjectNumber, successC); | ||
}; | ||
/** | ||
* For Android only (GCM or Firebase). | ||
*/ | ||
appsFlyer.updateServerUninstallToken = (token, successC) => { | ||
return RNAppsFlyer.updateServerUninstallToken(token, successC); | ||
}; | ||
appsFlyer.setCustomerUserId = (userId, successC,) => { | ||
@@ -50,0 +67,0 @@ return RNAppsFlyer.setCustomerUserId(userId, successC); |
{ | ||
"name": "react-native-appsflyer", | ||
"version": "1.0.12", | ||
"version": "1.1.1", | ||
"description": "React Native Appsflyer plugin", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -5,3 +5,3 @@ | ||
# react-native-appsflyer | ||
This React Native Library uses the AppsFlyer 4.6.0 library for both iOS and Android | ||
This React Native Library uses the AppsFlyer 4.7.1 library for both iOS and Android | ||
@@ -32,4 +32,4 @@ [![npm version](https://badge.fury.io/js/react-native-appsflyer.svg)](https://badge.fury.io/js/react-native-appsflyer) | ||
- iOS AppsFlyerSDK **v4.6.3** | ||
- Android AppsFlyerSDK **v4.6.5** | ||
- iOS AppsFlyerSDK **v4.7.1** | ||
- Android AppsFlyerSDK **v4.7.1** | ||
@@ -275,9 +275,10 @@ ## <a id="installation"> Installation | ||
`setGCMProjectID(GCMProjectID): void` | ||
~~`setGCMProjectID(GCMProjectID): void`~~ | ||
`enableUninstallTracking(GCMProjectNumber): void` | ||
Set the GCM API key. AppsFlyer requires a Google Project Number and GCM API Key to enable uninstall tracking. | ||
Set the GCM Project Number: AppsFlyer requires your Google Project Number to enable Uninstall Tracking. (For Firebase it's automatically retrieved from `google-services.json`) | ||
| parameter | type | description | | ||
| ----------- |-----------------------------|--------------| | ||
| `GCMProjectID` | `String` | | | ||
| `GCMProjectNumber` | `String` | | | ||
@@ -288,15 +289,30 @@ *Example:* | ||
setGCMProjectID(){ | ||
enableUninstallTracking(){ | ||
const gcmProjectId = "987186475229"; | ||
appsFlyer.setGCMProjectID(gcmProjectId, | ||
appsFlyer.enableUninstallTracking(gcmProjectId, | ||
(gcmProjectID) => { | ||
//... | ||
}, | ||
(error) => { | ||
console.error(error); | ||
}) | ||
} | ||
``` | ||
``` | ||
Alternatively if you have a GCM or Firebase token, you can provide it by using `updateServerUninstallToken` method: | ||
```javascript | ||
updateServerUninstallToken(){ | ||
const token = "xxxxxxxxxxxxx"; | ||
appsFlyer.updateServerUninstallToken(token, | ||
(response) => { | ||
this.setState( { ...this.state, tokenResponse: response }); | ||
}) | ||
} | ||
``` | ||
Read more about Android Uninstall Tracking: [Appsflyer SDK support site](https://support.appsflyer.com/hc/en-us/articles/208004986-Android-Uninstall-Tracking) | ||
@@ -303,0 +319,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
246495
30
88
487
1