mixpanel-react-native 2.3.1 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/MixpanelReactNative.podspec +1 -1
- package/Samples/ContextAPIMixpanel/Analytics.js +0 -6
- package/__tests__/index.test.js +186 -60
- package/__tests__/jest_setup.js +1 -0
- package/android/bin/.gradle/5.5/executionHistory/executionHistory.lock +0 -0
- package/android/bin/.gradle/5.5/fileChanges/last-build.bin +0 -0
- package/android/bin/.gradle/5.5/fileHashes/fileHashes.bin +0 -0
- package/android/bin/.gradle/5.5/fileHashes/fileHashes.lock +0 -0
- package/android/bin/.gradle/5.5/gc.properties +0 -0
- package/android/bin/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/bin/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/bin/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/bin/.gradle/vcs-1/gc.properties +0 -0
- package/android/bin/.idea/caches/build_file_checksums.ser +0 -0
- package/android/bin/.idea/compiler.xml +6 -0
- package/android/bin/.idea/gradle.xml +21 -0
- package/android/bin/.idea/jarRepositories.xml +30 -0
- package/android/bin/.idea/libraries/Gradle__com_android_support_appcompat_v7_23_0_1_aar.xml +16 -0
- package/android/bin/.idea/libraries/Gradle__com_android_support_recyclerview_v7_23_0_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_android_support_support_annotations_23_0_1.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_android_support_support_v4_23_0_1_aar.xml +17 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_fresco_drawee_0_8_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_fresco_fbcore_0_8_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_fresco_fresco_0_8_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_0_8_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_okhttp_0_8_1_aar.xml +13 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_react_react_native_0_20_1_aar.xml +17 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_stetho_stetho_1_2_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_facebook_stetho_stetho_okhttp_1_2_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_fasterxml_jackson_core_jackson_core_2_2_3.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_google_code_findbugs_jsr305_3_0_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_mixpanel_android_mixpanel_android_6_0_0_beta1_aar.xml +16 -0
- package/android/bin/.idea/libraries/Gradle__com_nineoldandroids_library_2_4_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_parse_bolts_bolts_android_1_1_4.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_squareup_okhttp_okhttp_2_5_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_squareup_okhttp_okhttp_ws_2_5_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__com_squareup_okio_okio_1_6_0.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__commons_cli_commons_cli_1_2.xml +11 -0
- package/android/bin/.idea/libraries/Gradle__org_webkit_android_jsc_r174650_aar.xml +11 -0
- package/android/bin/.idea/misc.xml +9 -0
- package/android/bin/.idea/modules.xml +8 -0
- package/android/bin/.idea/vcs.xml +6 -0
- package/android/bin/.idea/workspace.xml +57 -0
- package/android/bin/.project +34 -0
- package/android/bin/.settings/org.eclipse.buildship.core.prefs +13 -0
- package/android/bin/build.gradle +45 -0
- package/android/bin/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/bin/gradle/wrapper/gradle-wrapper.properties +6 -0
- package/android/bin/gradlew +172 -0
- package/android/bin/gradlew.bat +84 -0
- package/android/bin/local.properties +8 -0
- package/android/bin/src/main/AndroidManifest.xml +2 -0
- package/android/build.gradle +8 -1
- package/android/src/main/java/com/mixpanel/reactnative/MixpanelReactNativeModule.java +15 -1
- package/docs/Mixpanel.html +164 -25
- package/docs/MixpanelGroup.html +7 -7
- package/docs/People.html +12 -12
- package/docs/index.html +1 -1
- package/docs/index.js.html +14 -1
- package/index.d.ts +1 -1
- package/index.js +896 -820
- package/ios/MixpanelReactNative.m +2 -0
- package/ios/MixpanelReactNative.swift +10 -0
- package/package.json +56 -56
|
@@ -16,6 +16,8 @@ RCT_EXTERN_METHOD(setFlushOnBackground:(NSString *)token flushOnBackground:(BOOL
|
|
|
16
16
|
|
|
17
17
|
RCT_EXTERN_METHOD(setUseIpAddressForGeolocation:(NSString *)token useIpAddressForGeolocation:(BOOL)useIpAddressForGeolocation resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject)
|
|
18
18
|
|
|
19
|
+
RCT_EXTERN_METHOD(setFlushBatchSize:(NSString *)token flushBatchSize:(NSInteger)flushBatchSize resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject)
|
|
20
|
+
|
|
19
21
|
// MARK: - Opting Users Out of Tracking
|
|
20
22
|
|
|
21
23
|
RCT_EXTERN_METHOD(optOutTracking:(NSString *)token resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject)
|
|
@@ -59,6 +59,16 @@ open class MixpanelReactNative: NSObject {
|
|
|
59
59
|
resolve(nil)
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
+
@objc
|
|
63
|
+
func setFlushBatchSize(_ token: String,
|
|
64
|
+
flushBatchSize: Int,
|
|
65
|
+
resolver resolve: RCTPromiseResolveBlock,
|
|
66
|
+
rejecter reject: RCTPromiseRejectBlock) -> Void {
|
|
67
|
+
let instance = MixpanelReactNative.getMixpanelInstance(token)
|
|
68
|
+
instance?.flushBatchSize = flushBatchSize
|
|
69
|
+
resolve(nil)
|
|
70
|
+
}
|
|
71
|
+
|
|
62
72
|
@objc
|
|
63
73
|
func setUseIpAddressForGeolocation(_ token: String,
|
|
64
74
|
useIpAddressForGeolocation: Bool,
|
package/package.json
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
2
|
+
"name": "mixpanel-react-native",
|
|
3
|
+
"version": "2.4.1",
|
|
4
|
+
"description": "Official React Native Tracking Library for Mixpanel Analytics",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"test": "jest"
|
|
8
|
+
},
|
|
9
|
+
"author": "Mixpanel",
|
|
10
|
+
"license": "Apache-2.0",
|
|
11
|
+
"repository": {
|
|
12
|
+
"type": "git",
|
|
13
|
+
"url": "git+https://github.com/mixpanel/mixpanel-react-native.git"
|
|
14
|
+
},
|
|
15
|
+
"keywords": [
|
|
16
|
+
"mixpanel",
|
|
17
|
+
"react",
|
|
18
|
+
"native",
|
|
19
|
+
"ios",
|
|
20
|
+
"android",
|
|
21
|
+
"analytics",
|
|
22
|
+
"tracking",
|
|
23
|
+
"sdk"
|
|
24
|
+
],
|
|
25
|
+
"bugs": {
|
|
26
|
+
"url": "https://github.com/mixpanel/mixpanel-react-native/issues"
|
|
27
|
+
},
|
|
28
|
+
"TODO": "Change the git URL before publishing on npm",
|
|
29
|
+
"homepage": "https://github.com/mixpanel/mixpanel-react-native#readme",
|
|
30
|
+
"metadata": {
|
|
31
|
+
"mp_lib": "react-native"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@babel/core": "^7.12.3",
|
|
35
|
+
"@babel/runtime": "^7.12.1",
|
|
36
|
+
"@react-native-community/eslint-config": "^2.0.0",
|
|
37
|
+
"babel-jest": "^26.6.0",
|
|
38
|
+
"eslint": "^7.11.0",
|
|
39
|
+
"jest": "^26.6.0",
|
|
40
|
+
"metro-react-native-babel-preset": "^0.63.0",
|
|
41
|
+
"react-test-renderer": "16.13.1",
|
|
42
|
+
"react-native": "^0.63.3"
|
|
43
|
+
},
|
|
44
|
+
"jest": {
|
|
45
|
+
"modulePathIgnorePatterns": [
|
|
46
|
+
"<rootDir>/MixpanelDemo/"
|
|
24
47
|
],
|
|
25
|
-
"
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"@babel/runtime": "^7.12.1",
|
|
36
|
-
"@react-native-community/eslint-config": "^2.0.0",
|
|
37
|
-
"babel-jest": "^26.6.0",
|
|
38
|
-
"eslint": "^7.11.0",
|
|
39
|
-
"jest": "^26.6.0",
|
|
40
|
-
"metro-react-native-babel-preset": "^0.63.0",
|
|
41
|
-
"react-test-renderer": "16.13.1",
|
|
42
|
-
"react-native": "^0.63.3"
|
|
43
|
-
},
|
|
44
|
-
"jest": {
|
|
45
|
-
"modulePathIgnorePatterns": [
|
|
46
|
-
"<rootDir>/MixpanelDemo/"
|
|
47
|
-
],
|
|
48
|
-
"testMatch": [
|
|
49
|
-
"<rootDir>/__tests__/index.test.js"
|
|
50
|
-
],
|
|
51
|
-
"setupFiles": [
|
|
52
|
-
"<rootDir>/__tests__/jest_setup.js"
|
|
53
|
-
],
|
|
54
|
-
"verbose": true,
|
|
55
|
-
"preset": "react-native",
|
|
56
|
-
"transform": {
|
|
57
|
-
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js"
|
|
58
|
-
}
|
|
48
|
+
"testMatch": [
|
|
49
|
+
"<rootDir>/__tests__/index.test.js"
|
|
50
|
+
],
|
|
51
|
+
"setupFiles": [
|
|
52
|
+
"<rootDir>/__tests__/jest_setup.js"
|
|
53
|
+
],
|
|
54
|
+
"verbose": true,
|
|
55
|
+
"preset": "react-native",
|
|
56
|
+
"transform": {
|
|
57
|
+
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js"
|
|
59
58
|
}
|
|
59
|
+
}
|
|
60
60
|
}
|