@react-native-firebase/analytics 25.1.0 → 26.0.0

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.
Files changed (60) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/RNFBAnalytics.podspec +9 -5
  3. package/android/build.gradle +19 -0
  4. package/android/src/reactnative/java/io/invertase/firebase/analytics/{ReactNativeFirebaseAnalyticsModule.java → NativeRNFBTurboAnalytics.java} +57 -19
  5. package/android/src/reactnative/java/io/invertase/firebase/analytics/ReactNativeFirebaseAnalyticsPackage.java +1 -1
  6. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/java/com/facebook/fbreact/specs/NativeRNFBTurboAnalyticsSpec.java +100 -0
  7. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/jni/CMakeLists.txt +36 -0
  8. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/jni/RNFBAnalyticsTurboModules-generated.cpp +122 -0
  9. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/jni/RNFBAnalyticsTurboModules.h +31 -0
  10. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/jni/react/renderer/components/RNFBAnalyticsTurboModules/RNFBAnalyticsTurboModulesJSI-generated.cpp +131 -0
  11. package/android/src/reactnative/java/io/invertase/firebase/analytics/generated/jni/react/renderer/components/RNFBAnalyticsTurboModules/RNFBAnalyticsTurboModulesJSI.h +206 -0
  12. package/app.plugin.js +1 -1
  13. package/dist/module/index.js +965 -6
  14. package/dist/module/index.js.map +1 -1
  15. package/dist/module/types/analytics.js +1 -72
  16. package/dist/module/types/analytics.js.map +1 -1
  17. package/dist/module/version.js +1 -1
  18. package/dist/typescript/lib/index.d.ts +500 -4
  19. package/dist/typescript/lib/index.d.ts.map +1 -1
  20. package/dist/typescript/lib/types/analytics.d.ts +0 -103
  21. package/dist/typescript/lib/types/analytics.d.ts.map +1 -1
  22. package/dist/typescript/lib/types/internal.d.ts +1 -1
  23. package/dist/typescript/lib/types/internal.d.ts.map +1 -1
  24. package/dist/typescript/lib/version.d.ts +1 -1
  25. package/ios/RNFBAnalytics/RNFBAnalyticsModule.h +2 -2
  26. package/ios/RNFBAnalytics/{RNFBAnalyticsModule.m → RNFBAnalyticsModule.mm} +52 -66
  27. package/ios/RNFBAnalytics.xcodeproj/project.pbxproj +8 -8
  28. package/ios/generated/RCTAppDependencyProvider.h +25 -0
  29. package/ios/generated/RCTAppDependencyProvider.mm +55 -0
  30. package/ios/generated/RCTModulesConformingToProtocolsProvider.h +18 -0
  31. package/ios/generated/RCTModulesConformingToProtocolsProvider.mm +33 -0
  32. package/ios/generated/RCTThirdPartyComponentsProvider.h +16 -0
  33. package/ios/generated/RCTThirdPartyComponentsProvider.mm +23 -0
  34. package/ios/generated/RNFBAnalyticsTurboModules/RNFBAnalyticsTurboModules-generated.mm +144 -0
  35. package/ios/generated/RNFBAnalyticsTurboModules/RNFBAnalyticsTurboModules.h +108 -0
  36. package/ios/generated/RNFBAnalyticsTurboModulesJSI-generated.cpp +131 -0
  37. package/ios/generated/RNFBAnalyticsTurboModulesJSI.h +206 -0
  38. package/ios/generated/ReactAppDependencyProvider.podspec +34 -0
  39. package/lib/index.ts +1846 -7
  40. package/lib/types/analytics.ts +0 -118
  41. package/lib/types/internal.ts +1 -1
  42. package/lib/version.ts +1 -1
  43. package/package.json +30 -5
  44. package/plugin/build/app.plugin.d.ts +2 -0
  45. package/plugin/build/app.plugin.js +6 -0
  46. package/plugin/src/app.plugin.ts +3 -0
  47. package/plugin/tsconfig.tsbuildinfo +1 -1
  48. package/react-native.config.js +10 -0
  49. package/specs/NativeRNFBTurboAnalytics.ts +33 -0
  50. package/typedoc.json +2 -45
  51. package/dist/module/modular.js +0 -567
  52. package/dist/module/modular.js.map +0 -1
  53. package/dist/module/namespaced.js +0 -445
  54. package/dist/module/namespaced.js.map +0 -1
  55. package/dist/typescript/lib/modular.d.ts +0 -481
  56. package/dist/typescript/lib/modular.d.ts.map +0 -1
  57. package/dist/typescript/lib/namespaced.d.ts +0 -13
  58. package/dist/typescript/lib/namespaced.d.ts.map +0 -1
  59. package/lib/modular.ts +0 -1040
  60. package/lib/namespaced.ts +0 -915
@@ -0,0 +1,144 @@
1
+ /**
2
+ * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
+ *
4
+ * Do not edit this file as changes may cause incorrect behavior and will be lost
5
+ * once the code is regenerated.
6
+ *
7
+ * @generated by codegen project: GenerateModuleObjCpp
8
+ *
9
+ * We create an umbrella header (and corresponding implementation) here since
10
+ * Cxx compilation in BUCK has a limitation: source-code producing genrule()s
11
+ * must have a single output. More files => more genrule()s => slower builds.
12
+ */
13
+
14
+ #import "RNFBAnalyticsTurboModules.h"
15
+
16
+
17
+ @implementation NativeRNFBTurboAnalyticsSpecBase
18
+
19
+
20
+ - (void)setEventEmitterCallback:(EventEmitterCallbackWrapper *)eventEmitterCallbackWrapper
21
+ {
22
+ _eventEmitterCallback = std::move(eventEmitterCallbackWrapper->_eventEmitterCallback);
23
+ }
24
+ @end
25
+
26
+
27
+ namespace facebook::react {
28
+
29
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_logEvent(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
30
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "logEvent", @selector(logEvent:params:resolve:reject:), args, count);
31
+ }
32
+
33
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setAnalyticsCollectionEnabled(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
34
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setAnalyticsCollectionEnabled", @selector(setAnalyticsCollectionEnabled:resolve:reject:), args, count);
35
+ }
36
+
37
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setSessionTimeoutDuration(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
38
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setSessionTimeoutDuration", @selector(setSessionTimeoutDuration:resolve:reject:), args, count);
39
+ }
40
+
41
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_getAppInstanceId(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
42
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "getAppInstanceId", @selector(getAppInstanceId:reject:), args, count);
43
+ }
44
+
45
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_getSessionId(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
46
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "getSessionId", @selector(getSessionId:reject:), args, count);
47
+ }
48
+
49
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserId(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
50
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setUserId", @selector(setUserId:resolve:reject:), args, count);
51
+ }
52
+
53
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserProperty(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
54
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setUserProperty", @selector(setUserProperty:value:resolve:reject:), args, count);
55
+ }
56
+
57
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserProperties(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
58
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setUserProperties", @selector(setUserProperties:resolve:reject:), args, count);
59
+ }
60
+
61
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_resetAnalyticsData(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
62
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "resetAnalyticsData", @selector(resetAnalyticsData:reject:), args, count);
63
+ }
64
+
65
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setDefaultEventParameters(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
66
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setDefaultEventParameters", @selector(setDefaultEventParameters:resolve:reject:), args, count);
67
+ }
68
+
69
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setConsent(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
70
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "setConsent", @selector(setConsent:resolve:reject:), args, count);
71
+ }
72
+
73
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_logTransaction(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
74
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "logTransaction", @selector(logTransaction:resolve:reject:), args, count);
75
+ }
76
+
77
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithEmailAddress(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
78
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "initiateOnDeviceConversionMeasurementWithEmailAddress", @selector(initiateOnDeviceConversionMeasurementWithEmailAddress:resolve:reject:), args, count);
79
+ }
80
+
81
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithHashedEmailAddress(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
82
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "initiateOnDeviceConversionMeasurementWithHashedEmailAddress", @selector(initiateOnDeviceConversionMeasurementWithHashedEmailAddress:resolve:reject:), args, count);
83
+ }
84
+
85
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithPhoneNumber(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
86
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "initiateOnDeviceConversionMeasurementWithPhoneNumber", @selector(initiateOnDeviceConversionMeasurementWithPhoneNumber:resolve:reject:), args, count);
87
+ }
88
+
89
+ static facebook::jsi::Value __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
90
+ return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, PromiseKind, "initiateOnDeviceConversionMeasurementWithHashedPhoneNumber", @selector(initiateOnDeviceConversionMeasurementWithHashedPhoneNumber:resolve:reject:), args, count);
91
+ }
92
+
93
+ NativeRNFBTurboAnalyticsSpecJSI::NativeRNFBTurboAnalyticsSpecJSI(const ObjCTurboModule::InitParams &params)
94
+ : ObjCTurboModule(params) {
95
+
96
+ methodMap_["logEvent"] = MethodMetadata {2, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_logEvent};
97
+
98
+
99
+ methodMap_["setAnalyticsCollectionEnabled"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setAnalyticsCollectionEnabled};
100
+
101
+
102
+ methodMap_["setSessionTimeoutDuration"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setSessionTimeoutDuration};
103
+
104
+
105
+ methodMap_["getAppInstanceId"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_getAppInstanceId};
106
+
107
+
108
+ methodMap_["getSessionId"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_getSessionId};
109
+
110
+
111
+ methodMap_["setUserId"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserId};
112
+
113
+
114
+ methodMap_["setUserProperty"] = MethodMetadata {2, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserProperty};
115
+
116
+
117
+ methodMap_["setUserProperties"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setUserProperties};
118
+
119
+
120
+ methodMap_["resetAnalyticsData"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_resetAnalyticsData};
121
+
122
+
123
+ methodMap_["setDefaultEventParameters"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setDefaultEventParameters};
124
+
125
+
126
+ methodMap_["setConsent"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_setConsent};
127
+
128
+
129
+ methodMap_["logTransaction"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_logTransaction};
130
+
131
+
132
+ methodMap_["initiateOnDeviceConversionMeasurementWithEmailAddress"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithEmailAddress};
133
+
134
+
135
+ methodMap_["initiateOnDeviceConversionMeasurementWithHashedEmailAddress"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithHashedEmailAddress};
136
+
137
+
138
+ methodMap_["initiateOnDeviceConversionMeasurementWithPhoneNumber"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithPhoneNumber};
139
+
140
+
141
+ methodMap_["initiateOnDeviceConversionMeasurementWithHashedPhoneNumber"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsSpecJSI_initiateOnDeviceConversionMeasurementWithHashedPhoneNumber};
142
+
143
+ }
144
+ } // namespace facebook::react
@@ -0,0 +1,108 @@
1
+ /**
2
+ * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
+ *
4
+ * Do not edit this file as changes may cause incorrect behavior and will be lost
5
+ * once the code is regenerated.
6
+ *
7
+ * @generated by codegen project: GenerateModuleObjCpp
8
+ *
9
+ * We create an umbrella header (and corresponding implementation) here since
10
+ * Cxx compilation in BUCK has a limitation: source-code producing genrule()s
11
+ * must have a single output. More files => more genrule()s => slower builds.
12
+ */
13
+
14
+ #ifndef __cplusplus
15
+ #error This file must be compiled as Obj-C++. If you are importing it, you must change your file extension to .mm.
16
+ #endif
17
+
18
+ // Avoid multiple includes of RNFBAnalyticsTurboModules symbols
19
+ #ifndef RNFBAnalyticsTurboModules_H
20
+ #define RNFBAnalyticsTurboModules_H
21
+
22
+ #import <Foundation/Foundation.h>
23
+ #import <RCTRequired/RCTRequired.h>
24
+ #import <RCTTypeSafety/RCTConvertHelpers.h>
25
+ #import <RCTTypeSafety/RCTTypedModuleConstants.h>
26
+ #import <React/RCTBridgeModule.h>
27
+ #import <React/RCTCxxConvert.h>
28
+ #import <React/RCTManagedPointer.h>
29
+ #import <ReactCommon/RCTTurboModule.h>
30
+ #import <optional>
31
+ #import <vector>
32
+
33
+
34
+ NS_ASSUME_NONNULL_BEGIN
35
+
36
+ @protocol NativeRNFBTurboAnalyticsSpec <RCTBridgeModule, RCTTurboModule>
37
+
38
+ - (void)logEvent:(NSString *)name
39
+ params:(NSDictionary * _Nullable)params
40
+ resolve:(RCTPromiseResolveBlock)resolve
41
+ reject:(RCTPromiseRejectBlock)reject;
42
+ - (void)setAnalyticsCollectionEnabled:(BOOL)enabled
43
+ resolve:(RCTPromiseResolveBlock)resolve
44
+ reject:(RCTPromiseRejectBlock)reject;
45
+ - (void)setSessionTimeoutDuration:(double)milliseconds
46
+ resolve:(RCTPromiseResolveBlock)resolve
47
+ reject:(RCTPromiseRejectBlock)reject;
48
+ - (void)getAppInstanceId:(RCTPromiseResolveBlock)resolve
49
+ reject:(RCTPromiseRejectBlock)reject;
50
+ - (void)getSessionId:(RCTPromiseResolveBlock)resolve
51
+ reject:(RCTPromiseRejectBlock)reject;
52
+ - (void)setUserId:(NSString * _Nullable)id
53
+ resolve:(RCTPromiseResolveBlock)resolve
54
+ reject:(RCTPromiseRejectBlock)reject;
55
+ - (void)setUserProperty:(NSString *)name
56
+ value:(NSString * _Nullable)value
57
+ resolve:(RCTPromiseResolveBlock)resolve
58
+ reject:(RCTPromiseRejectBlock)reject;
59
+ - (void)setUserProperties:(NSDictionary *)properties
60
+ resolve:(RCTPromiseResolveBlock)resolve
61
+ reject:(RCTPromiseRejectBlock)reject;
62
+ - (void)resetAnalyticsData:(RCTPromiseResolveBlock)resolve
63
+ reject:(RCTPromiseRejectBlock)reject;
64
+ - (void)setDefaultEventParameters:(NSDictionary * _Nullable)params
65
+ resolve:(RCTPromiseResolveBlock)resolve
66
+ reject:(RCTPromiseRejectBlock)reject;
67
+ - (void)setConsent:(NSDictionary *)consentSettings
68
+ resolve:(RCTPromiseResolveBlock)resolve
69
+ reject:(RCTPromiseRejectBlock)reject;
70
+ - (void)logTransaction:(NSString *)transactionId
71
+ resolve:(RCTPromiseResolveBlock)resolve
72
+ reject:(RCTPromiseRejectBlock)reject;
73
+ - (void)initiateOnDeviceConversionMeasurementWithEmailAddress:(NSString *)emailAddress
74
+ resolve:(RCTPromiseResolveBlock)resolve
75
+ reject:(RCTPromiseRejectBlock)reject;
76
+ - (void)initiateOnDeviceConversionMeasurementWithHashedEmailAddress:(NSString *)hashedEmailAddress
77
+ resolve:(RCTPromiseResolveBlock)resolve
78
+ reject:(RCTPromiseRejectBlock)reject;
79
+ - (void)initiateOnDeviceConversionMeasurementWithPhoneNumber:(NSString *)phoneNumber
80
+ resolve:(RCTPromiseResolveBlock)resolve
81
+ reject:(RCTPromiseRejectBlock)reject;
82
+ - (void)initiateOnDeviceConversionMeasurementWithHashedPhoneNumber:(NSString *)hashedPhoneNumber
83
+ resolve:(RCTPromiseResolveBlock)resolve
84
+ reject:(RCTPromiseRejectBlock)reject;
85
+
86
+ @end
87
+
88
+ @interface NativeRNFBTurboAnalyticsSpecBase : NSObject {
89
+ @protected
90
+ facebook::react::EventEmitterCallback _eventEmitterCallback;
91
+ }
92
+ - (void)setEventEmitterCallback:(EventEmitterCallbackWrapper *)eventEmitterCallbackWrapper;
93
+
94
+
95
+ @end
96
+
97
+ namespace facebook::react {
98
+ /**
99
+ * ObjC++ class for module 'NativeRNFBTurboAnalytics'
100
+ */
101
+ class JSI_EXPORT NativeRNFBTurboAnalyticsSpecJSI : public ObjCTurboModule {
102
+ public:
103
+ NativeRNFBTurboAnalyticsSpecJSI(const ObjCTurboModule::InitParams &params);
104
+ };
105
+ } // namespace facebook::react
106
+
107
+ NS_ASSUME_NONNULL_END
108
+ #endif // RNFBAnalyticsTurboModules_H
@@ -0,0 +1,131 @@
1
+ /**
2
+ * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
+ *
4
+ * Do not edit this file as changes may cause incorrect behavior and will be lost
5
+ * once the code is regenerated.
6
+ *
7
+ * @generated by codegen project: GenerateModuleCpp.js
8
+ */
9
+
10
+ #include "RNFBAnalyticsTurboModulesJSI.h"
11
+
12
+ namespace facebook::react {
13
+
14
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_logEvent(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
15
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->logEvent(
16
+ rt,
17
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
18
+ count <= 1 || args[1].isNull() || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asObject(rt))
19
+ );
20
+ }
21
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setAnalyticsCollectionEnabled(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
22
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setAnalyticsCollectionEnabled(
23
+ rt,
24
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asBool()
25
+ );
26
+ }
27
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setSessionTimeoutDuration(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
28
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setSessionTimeoutDuration(
29
+ rt,
30
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber()
31
+ );
32
+ }
33
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_getAppInstanceId(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
34
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->getAppInstanceId(
35
+ rt
36
+ );
37
+ }
38
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_getSessionId(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
39
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->getSessionId(
40
+ rt
41
+ );
42
+ }
43
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserId(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
44
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setUserId(
45
+ rt,
46
+ count <= 0 || args[0].isNull() || args[0].isUndefined() ? std::nullopt : std::make_optional(args[0].asString(rt))
47
+ );
48
+ }
49
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserProperty(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
50
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setUserProperty(
51
+ rt,
52
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
53
+ count <= 1 || args[1].isNull() || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asString(rt))
54
+ );
55
+ }
56
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserProperties(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
57
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setUserProperties(
58
+ rt,
59
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt)
60
+ );
61
+ }
62
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_resetAnalyticsData(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
63
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->resetAnalyticsData(
64
+ rt
65
+ );
66
+ }
67
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setDefaultEventParameters(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
68
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setDefaultEventParameters(
69
+ rt,
70
+ count <= 0 || args[0].isNull() || args[0].isUndefined() ? std::nullopt : std::make_optional(args[0].asObject(rt))
71
+ );
72
+ }
73
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setConsent(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
74
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->setConsent(
75
+ rt,
76
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt)
77
+ );
78
+ }
79
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_logTransaction(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
80
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->logTransaction(
81
+ rt,
82
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
83
+ );
84
+ }
85
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithEmailAddress(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
86
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->initiateOnDeviceConversionMeasurementWithEmailAddress(
87
+ rt,
88
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
89
+ );
90
+ }
91
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithHashedEmailAddress(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
92
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->initiateOnDeviceConversionMeasurementWithHashedEmailAddress(
93
+ rt,
94
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
95
+ );
96
+ }
97
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithPhoneNumber(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
98
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->initiateOnDeviceConversionMeasurementWithPhoneNumber(
99
+ rt,
100
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
101
+ );
102
+ }
103
+ static jsi::Value __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
104
+ return static_cast<NativeRNFBTurboAnalyticsCxxSpecJSI *>(&turboModule)->initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(
105
+ rt,
106
+ count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
107
+ );
108
+ }
109
+
110
+ NativeRNFBTurboAnalyticsCxxSpecJSI::NativeRNFBTurboAnalyticsCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
111
+ : TurboModule("NativeRNFBTurboAnalytics", jsInvoker) {
112
+ methodMap_["logEvent"] = MethodMetadata {2, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_logEvent};
113
+ methodMap_["setAnalyticsCollectionEnabled"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setAnalyticsCollectionEnabled};
114
+ methodMap_["setSessionTimeoutDuration"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setSessionTimeoutDuration};
115
+ methodMap_["getAppInstanceId"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_getAppInstanceId};
116
+ methodMap_["getSessionId"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_getSessionId};
117
+ methodMap_["setUserId"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserId};
118
+ methodMap_["setUserProperty"] = MethodMetadata {2, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserProperty};
119
+ methodMap_["setUserProperties"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setUserProperties};
120
+ methodMap_["resetAnalyticsData"] = MethodMetadata {0, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_resetAnalyticsData};
121
+ methodMap_["setDefaultEventParameters"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setDefaultEventParameters};
122
+ methodMap_["setConsent"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_setConsent};
123
+ methodMap_["logTransaction"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_logTransaction};
124
+ methodMap_["initiateOnDeviceConversionMeasurementWithEmailAddress"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithEmailAddress};
125
+ methodMap_["initiateOnDeviceConversionMeasurementWithHashedEmailAddress"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithHashedEmailAddress};
126
+ methodMap_["initiateOnDeviceConversionMeasurementWithPhoneNumber"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithPhoneNumber};
127
+ methodMap_["initiateOnDeviceConversionMeasurementWithHashedPhoneNumber"] = MethodMetadata {1, __hostFunction_NativeRNFBTurboAnalyticsCxxSpecJSI_initiateOnDeviceConversionMeasurementWithHashedPhoneNumber};
128
+ }
129
+
130
+
131
+ } // namespace facebook::react
@@ -0,0 +1,206 @@
1
+ /**
2
+ * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
+ *
4
+ * Do not edit this file as changes may cause incorrect behavior and will be lost
5
+ * once the code is regenerated.
6
+ *
7
+ * @generated by codegen project: GenerateModuleH.js
8
+ */
9
+
10
+ #pragma once
11
+
12
+ #include <ReactCommon/TurboModule.h>
13
+ #include <react/bridging/Bridging.h>
14
+
15
+ namespace facebook::react {
16
+
17
+
18
+ class JSI_EXPORT NativeRNFBTurboAnalyticsCxxSpecJSI : public TurboModule {
19
+ protected:
20
+ NativeRNFBTurboAnalyticsCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker);
21
+
22
+ public:
23
+ virtual jsi::Value logEvent(jsi::Runtime &rt, jsi::String name, std::optional<jsi::Object> params) = 0;
24
+ virtual jsi::Value setAnalyticsCollectionEnabled(jsi::Runtime &rt, bool enabled) = 0;
25
+ virtual jsi::Value setSessionTimeoutDuration(jsi::Runtime &rt, double milliseconds) = 0;
26
+ virtual jsi::Value getAppInstanceId(jsi::Runtime &rt) = 0;
27
+ virtual jsi::Value getSessionId(jsi::Runtime &rt) = 0;
28
+ virtual jsi::Value setUserId(jsi::Runtime &rt, std::optional<jsi::String> id) = 0;
29
+ virtual jsi::Value setUserProperty(jsi::Runtime &rt, jsi::String name, std::optional<jsi::String> value) = 0;
30
+ virtual jsi::Value setUserProperties(jsi::Runtime &rt, jsi::Object properties) = 0;
31
+ virtual jsi::Value resetAnalyticsData(jsi::Runtime &rt) = 0;
32
+ virtual jsi::Value setDefaultEventParameters(jsi::Runtime &rt, std::optional<jsi::Object> params) = 0;
33
+ virtual jsi::Value setConsent(jsi::Runtime &rt, jsi::Object consentSettings) = 0;
34
+ virtual jsi::Value logTransaction(jsi::Runtime &rt, jsi::String transactionId) = 0;
35
+ virtual jsi::Value initiateOnDeviceConversionMeasurementWithEmailAddress(jsi::Runtime &rt, jsi::String emailAddress) = 0;
36
+ virtual jsi::Value initiateOnDeviceConversionMeasurementWithHashedEmailAddress(jsi::Runtime &rt, jsi::String hashedEmailAddress) = 0;
37
+ virtual jsi::Value initiateOnDeviceConversionMeasurementWithPhoneNumber(jsi::Runtime &rt, jsi::String phoneNumber) = 0;
38
+ virtual jsi::Value initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(jsi::Runtime &rt, jsi::String hashedPhoneNumber) = 0;
39
+
40
+ };
41
+
42
+ template <typename T>
43
+ class JSI_EXPORT NativeRNFBTurboAnalyticsCxxSpec : public TurboModule {
44
+ public:
45
+ jsi::Value create(jsi::Runtime &rt, const jsi::PropNameID &propName) override {
46
+ return delegate_.create(rt, propName);
47
+ }
48
+
49
+ std::vector<jsi::PropNameID> getPropertyNames(jsi::Runtime& runtime) override {
50
+ return delegate_.getPropertyNames(runtime);
51
+ }
52
+
53
+ static constexpr std::string_view kModuleName = "NativeRNFBTurboAnalytics";
54
+
55
+ protected:
56
+ NativeRNFBTurboAnalyticsCxxSpec(std::shared_ptr<CallInvoker> jsInvoker)
57
+ : TurboModule(std::string{NativeRNFBTurboAnalyticsCxxSpec::kModuleName}, jsInvoker),
58
+ delegate_(reinterpret_cast<T*>(this), jsInvoker) {}
59
+
60
+
61
+ private:
62
+ class Delegate : public NativeRNFBTurboAnalyticsCxxSpecJSI {
63
+ public:
64
+ Delegate(T *instance, std::shared_ptr<CallInvoker> jsInvoker) :
65
+ NativeRNFBTurboAnalyticsCxxSpecJSI(std::move(jsInvoker)), instance_(instance) {
66
+
67
+ }
68
+
69
+ jsi::Value logEvent(jsi::Runtime &rt, jsi::String name, std::optional<jsi::Object> params) override {
70
+ static_assert(
71
+ bridging::getParameterCount(&T::logEvent) == 3,
72
+ "Expected logEvent(...) to have 3 parameters");
73
+
74
+ return bridging::callFromJs<jsi::Value>(
75
+ rt, &T::logEvent, jsInvoker_, instance_, std::move(name), std::move(params));
76
+ }
77
+ jsi::Value setAnalyticsCollectionEnabled(jsi::Runtime &rt, bool enabled) override {
78
+ static_assert(
79
+ bridging::getParameterCount(&T::setAnalyticsCollectionEnabled) == 2,
80
+ "Expected setAnalyticsCollectionEnabled(...) to have 2 parameters");
81
+
82
+ return bridging::callFromJs<jsi::Value>(
83
+ rt, &T::setAnalyticsCollectionEnabled, jsInvoker_, instance_, std::move(enabled));
84
+ }
85
+ jsi::Value setSessionTimeoutDuration(jsi::Runtime &rt, double milliseconds) override {
86
+ static_assert(
87
+ bridging::getParameterCount(&T::setSessionTimeoutDuration) == 2,
88
+ "Expected setSessionTimeoutDuration(...) to have 2 parameters");
89
+
90
+ return bridging::callFromJs<jsi::Value>(
91
+ rt, &T::setSessionTimeoutDuration, jsInvoker_, instance_, std::move(milliseconds));
92
+ }
93
+ jsi::Value getAppInstanceId(jsi::Runtime &rt) override {
94
+ static_assert(
95
+ bridging::getParameterCount(&T::getAppInstanceId) == 1,
96
+ "Expected getAppInstanceId(...) to have 1 parameters");
97
+
98
+ return bridging::callFromJs<jsi::Value>(
99
+ rt, &T::getAppInstanceId, jsInvoker_, instance_);
100
+ }
101
+ jsi::Value getSessionId(jsi::Runtime &rt) override {
102
+ static_assert(
103
+ bridging::getParameterCount(&T::getSessionId) == 1,
104
+ "Expected getSessionId(...) to have 1 parameters");
105
+
106
+ return bridging::callFromJs<jsi::Value>(
107
+ rt, &T::getSessionId, jsInvoker_, instance_);
108
+ }
109
+ jsi::Value setUserId(jsi::Runtime &rt, std::optional<jsi::String> id) override {
110
+ static_assert(
111
+ bridging::getParameterCount(&T::setUserId) == 2,
112
+ "Expected setUserId(...) to have 2 parameters");
113
+
114
+ return bridging::callFromJs<jsi::Value>(
115
+ rt, &T::setUserId, jsInvoker_, instance_, std::move(id));
116
+ }
117
+ jsi::Value setUserProperty(jsi::Runtime &rt, jsi::String name, std::optional<jsi::String> value) override {
118
+ static_assert(
119
+ bridging::getParameterCount(&T::setUserProperty) == 3,
120
+ "Expected setUserProperty(...) to have 3 parameters");
121
+
122
+ return bridging::callFromJs<jsi::Value>(
123
+ rt, &T::setUserProperty, jsInvoker_, instance_, std::move(name), std::move(value));
124
+ }
125
+ jsi::Value setUserProperties(jsi::Runtime &rt, jsi::Object properties) override {
126
+ static_assert(
127
+ bridging::getParameterCount(&T::setUserProperties) == 2,
128
+ "Expected setUserProperties(...) to have 2 parameters");
129
+
130
+ return bridging::callFromJs<jsi::Value>(
131
+ rt, &T::setUserProperties, jsInvoker_, instance_, std::move(properties));
132
+ }
133
+ jsi::Value resetAnalyticsData(jsi::Runtime &rt) override {
134
+ static_assert(
135
+ bridging::getParameterCount(&T::resetAnalyticsData) == 1,
136
+ "Expected resetAnalyticsData(...) to have 1 parameters");
137
+
138
+ return bridging::callFromJs<jsi::Value>(
139
+ rt, &T::resetAnalyticsData, jsInvoker_, instance_);
140
+ }
141
+ jsi::Value setDefaultEventParameters(jsi::Runtime &rt, std::optional<jsi::Object> params) override {
142
+ static_assert(
143
+ bridging::getParameterCount(&T::setDefaultEventParameters) == 2,
144
+ "Expected setDefaultEventParameters(...) to have 2 parameters");
145
+
146
+ return bridging::callFromJs<jsi::Value>(
147
+ rt, &T::setDefaultEventParameters, jsInvoker_, instance_, std::move(params));
148
+ }
149
+ jsi::Value setConsent(jsi::Runtime &rt, jsi::Object consentSettings) override {
150
+ static_assert(
151
+ bridging::getParameterCount(&T::setConsent) == 2,
152
+ "Expected setConsent(...) to have 2 parameters");
153
+
154
+ return bridging::callFromJs<jsi::Value>(
155
+ rt, &T::setConsent, jsInvoker_, instance_, std::move(consentSettings));
156
+ }
157
+ jsi::Value logTransaction(jsi::Runtime &rt, jsi::String transactionId) override {
158
+ static_assert(
159
+ bridging::getParameterCount(&T::logTransaction) == 2,
160
+ "Expected logTransaction(...) to have 2 parameters");
161
+
162
+ return bridging::callFromJs<jsi::Value>(
163
+ rt, &T::logTransaction, jsInvoker_, instance_, std::move(transactionId));
164
+ }
165
+ jsi::Value initiateOnDeviceConversionMeasurementWithEmailAddress(jsi::Runtime &rt, jsi::String emailAddress) override {
166
+ static_assert(
167
+ bridging::getParameterCount(&T::initiateOnDeviceConversionMeasurementWithEmailAddress) == 2,
168
+ "Expected initiateOnDeviceConversionMeasurementWithEmailAddress(...) to have 2 parameters");
169
+
170
+ return bridging::callFromJs<jsi::Value>(
171
+ rt, &T::initiateOnDeviceConversionMeasurementWithEmailAddress, jsInvoker_, instance_, std::move(emailAddress));
172
+ }
173
+ jsi::Value initiateOnDeviceConversionMeasurementWithHashedEmailAddress(jsi::Runtime &rt, jsi::String hashedEmailAddress) override {
174
+ static_assert(
175
+ bridging::getParameterCount(&T::initiateOnDeviceConversionMeasurementWithHashedEmailAddress) == 2,
176
+ "Expected initiateOnDeviceConversionMeasurementWithHashedEmailAddress(...) to have 2 parameters");
177
+
178
+ return bridging::callFromJs<jsi::Value>(
179
+ rt, &T::initiateOnDeviceConversionMeasurementWithHashedEmailAddress, jsInvoker_, instance_, std::move(hashedEmailAddress));
180
+ }
181
+ jsi::Value initiateOnDeviceConversionMeasurementWithPhoneNumber(jsi::Runtime &rt, jsi::String phoneNumber) override {
182
+ static_assert(
183
+ bridging::getParameterCount(&T::initiateOnDeviceConversionMeasurementWithPhoneNumber) == 2,
184
+ "Expected initiateOnDeviceConversionMeasurementWithPhoneNumber(...) to have 2 parameters");
185
+
186
+ return bridging::callFromJs<jsi::Value>(
187
+ rt, &T::initiateOnDeviceConversionMeasurementWithPhoneNumber, jsInvoker_, instance_, std::move(phoneNumber));
188
+ }
189
+ jsi::Value initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(jsi::Runtime &rt, jsi::String hashedPhoneNumber) override {
190
+ static_assert(
191
+ bridging::getParameterCount(&T::initiateOnDeviceConversionMeasurementWithHashedPhoneNumber) == 2,
192
+ "Expected initiateOnDeviceConversionMeasurementWithHashedPhoneNumber(...) to have 2 parameters");
193
+
194
+ return bridging::callFromJs<jsi::Value>(
195
+ rt, &T::initiateOnDeviceConversionMeasurementWithHashedPhoneNumber, jsInvoker_, instance_, std::move(hashedPhoneNumber));
196
+ }
197
+
198
+ private:
199
+ friend class NativeRNFBTurboAnalyticsCxxSpec;
200
+ T *instance_;
201
+ };
202
+
203
+ Delegate delegate_;
204
+ };
205
+
206
+ } // namespace facebook::react
@@ -0,0 +1,34 @@
1
+ # Copyright (c) Meta Platforms, Inc. and affiliates.
2
+ #
3
+ # This source code is licensed under the MIT license found in the
4
+ # LICENSE file in the root directory of this source tree.
5
+
6
+ version = "0.78.3"
7
+ source = { :git => 'https://github.com/facebook/react-native.git' }
8
+ if version == '1000.0.0'
9
+ # This is an unpublished version, use the latest commit hash of the react-native repo, which we’re presumably in.
10
+ source[:commit] = `git rev-parse HEAD`.strip if system("git rev-parse --git-dir > /dev/null 2>&1")
11
+ else
12
+ source[:tag] = "v#{version}"
13
+ end
14
+
15
+ Pod::Spec.new do |s|
16
+ s.name = "ReactAppDependencyProvider"
17
+ s.version = version
18
+ s.summary = "The third party dependency provider for the app"
19
+ s.homepage = "https://reactnative.dev/"
20
+ s.documentation_url = "https://reactnative.dev/"
21
+ s.license = "MIT"
22
+ s.author = "Meta Platforms, Inc. and its affiliates"
23
+ s.platforms = min_supported_versions
24
+ s.source = source
25
+ s.source_files = "**/RCTAppDependencyProvider.{h,mm}"
26
+
27
+ # This guard prevent to install the dependencies when we run `pod install` in the old architecture.
28
+ s.pod_target_xcconfig = {
29
+ "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
30
+ "DEFINES_MODULE" => "YES"
31
+ }
32
+
33
+ s.dependency "ReactCodegen"
34
+ end