You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: upgrade E2E-latest to RN 0.84.1 to demonstrate breaking issues
- Upgraded from RN 0.76.1 to RN 0.84.1
- Upgraded from React 18.2.0 to React 19.2.3
- Fixed Podfile to remove deprecated __apply_Xcode_12_5_M1_post_install_workaround
- Added root metro.config.js to handle workspace Metro resolution
Breaking Issues Identified:
- Podfile post-install workaround removed in RN 0.84
- Package version incompatibilities (@types/react-native, metro configs)
- New Architecture (Fabric) enabled by default causes build failures
- Third-party libraries (react-native-safe-area-context) not compatible with New Architecture
Build currently fails with:
CompileC RNCSafeAreaViewShadowNode.cpp - New Architecture incompatibility
This demonstrates the real-world upgrade challenges users will face.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: examples/E2E-latest/App.tsx
+17-5Lines changed: 17 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,8 @@ import Home from './Home';
20
20
importSecondPagefrom'./SecondPage';
21
21
importModalfrom'./Modal';
22
22
import{useState}from'react';
23
-
//import {Logger} from './plugins/Logger';
23
+
import{Logger}from'./plugins/Logger';
24
+
import{Platform}from'react-native';
24
25
25
26
// import {AmplitudeSessionPlugin} from '@segment/analytics-react-native-plugin-amplitude-session';
26
27
// import { ConsentManager } from './plugins/ConsentManager';
@@ -32,22 +33,33 @@ import {useState} from 'react';
32
33
// import { BrazePlugin } from '@segment/analytics-react-native-plugin-braze';
33
34
34
35
constsegmentClient=createClient({
35
-
writeKey: '<write-key>',
36
+
writeKey: 'yup',
37
+
maxBatchSize: 1000,
38
+
trackDeepLinks: true,
36
39
trackAppLifecycleEvents: true,
40
+
autoAddSegmentDestination: true,
37
41
collectDeviceId: true,
38
42
debug: true,
39
-
trackDeepLinks: true,
43
+
useSegmentEndpoints: true,//if you pass only domain/v1 as proxy setup, use this flag to append segment endpoints. Otherwise you can remove it and customise proxy completely
40
44
flushPolicies: [
41
45
newCountFlushPolicy(5),
42
46
// These are disabled for E2E tests
43
47
// new TimerFlushPolicy(1000),
44
48
// new StartupFlushPolicy(),
45
49
],
50
+
proxy: Platform.select({
51
+
ios: 'http://localhost:9091/v1',
52
+
android: 'http://10.0.2.2:9091/v1',
53
+
}),
54
+
cdnProxy: Platform.select({
55
+
ios: 'http://localhost:9091/v1',
56
+
android: 'http://10.0.2.2:9091/v1',
57
+
}),
46
58
});
47
59
48
-
// const LoggerPlugin = new Logger();
60
+
constLoggerPlugin=newLogger();
49
61
50
-
// segmentClient.add({plugin: LoggerPlugin});
62
+
segmentClient.add({plugin: LoggerPlugin});
51
63
52
64
// To see an example Consent Manager uncomment the following
53
65
// const ConsentManagerPlugin = new ConsentManager();
0 commit comments