feat: added example app to support rn0.83 - #10
Open
sunitaprajapati89 wants to merge 3 commits into
Open
Conversation
added 3 commits
July 21, 2026 16:05
- Bump plugin version to 2.0.0 - Update Amazon peer deps to rn-83 versions (kepler 4.0.0, device-info/localize/async-storage 2.1.9000000000-rn-83) - Update devDeps toolchain to RN 0.83 / React 19 / react-native-builder-bob 0.43 - Pin @segment/analytics-react-native to 2.20.0-beta.2 (2.21.4 has hard native crashes on Kepler 4 New Architecture) - Add native-module-polyfill.js shim to prevent __fbBatchedBridgeConfig crash on Kepler 4 - Chain metro.config.js resolveRequest to Kepler's own resolver to avoid bundling standard RN instead of Kepler runtime - Add @amzn/react-native-kepler extraNodeModules alias to fix Metro asset resolution - Update manifest.toml to kepler_4 runtime module - Fix UI layout in App.tsx and Link.tsx (reduce oversized margins and font sizes for virtual device) - Fix deprecated moduleResolution: node → bundler in both tsconfig files - Remove deprecated baseUrl from root tsconfig - Update README with Vega SDK 0.24 install steps and metro.config.js setup instructions
….21.4 on Kepler 4
Kepler 4 (Vega SDK 0.24) is New Architecture only — NativeModules throws
__fbBatchedBridgeConfig at module-load time and cannot be caught in user code.
Three Metro resolveRequest intercepts replace the offending modules with
pure-JS shims before they are loaded:
- get-random-values-polyfill.js: replaces react-native-get-random-values
with a Math.random fallback (RNGetRandomValues TurboModule absent on Kepler)
- sovran-polyfill.js: replaces @segment/sovran-react-native entry point with
pure-JS store/bridge/persistor exports, bypassing the NativeModules getter
- context-polyfill.js: replaces analytics-react-native context.ts which calls
getNativeModule('AnalyticsReactNative') — safe because the Kepler plugin
provides its own deviceInfoProvider
Also:
- Remove native-module-polyfill.js (superseded by the above three shims)
- Update example-83/package.json to use published 2.21.4 from npm registry
- Update metro.config.js: chain keplerResolveRequest, add transformIgnorePatterns
for @segment scope, remove stale commented-out block
- Fix deprecated moduleResolution: node → bundler in root tsconfig.json
- Update README with complete setup guide including all three shims,
full metro.config.js, and root cause explanation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add example-83 app for React Native 0.83 / Vega SDK 0.24 support
Summary
Plugin changes (v1.0.0 → v2.0.0)
example-83 app
Mirrors the existing example/ app with the following RN 0.83 toolchain changes:
Notes
The existing example/ app and v1.0.0 of the plugin are untouched — RN 0.72 apps continue to work as before
The -rn-83 version suffixes on Amazon packages are early-access build identifiers; confirm final published versions before a GA release
Requires Vega SDK 0.24 device image (keplerscript_4) on the virtual device; older OS images will reject the install