Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@
- Support New Hermes Runtime Access Pattern ([#5051](https://github.com/getsentry/sentry-react-native/pull/5051))
- Support Metro 0.83 ([#5035](https://github.com/getsentry/sentry-react-native/pull/5035))

### Fixes

- Correct detection of whether turbo modules are available ([#5064](https://github.com/getsentry/sentry-react-native/pull/5064))

### Dependencies

- Bump CLI from v2.50.2 to v2.51.1 ([#5053](https://github.com/getsentry/sentry-react-native/pull/5053), [#5058](https://github.com/getsentry/sentry-react-native/pull/5058))
Expand Down
3 changes: 2 additions & 1 deletion packages/core/src/js/utils/environment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ export function isHermesEnabled(): boolean {

/** Checks if the React Native TurboModules are enabled */
export function isTurboModuleEnabled(): boolean {
return RN_GLOBAL_OBJ.__turboModuleProxy != null;
// Reference: https://github.com/facebook/react-native/blob/641a79dc5137b69a3c0813413b9fb82d0b9df783/packages/react-native/src/private/featureflags/ReactNativeFeatureFlagsBase.js#L110
return RN_GLOBAL_OBJ.RN$Bridgeless === true || RN_GLOBAL_OBJ.__turboModuleProxy != null;
}

/** Checks if the React Native Fabric renderer is running */
Expand Down
1 change: 1 addition & 0 deletions packages/core/src/js/utils/worldwide.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export interface ReactNativeInternalGlobal extends InternalGlobal {
};
Promise: unknown;
__turboModuleProxy: unknown;
RN$Bridgeless: unknown;
nativeFabricUIManager: unknown;
ErrorUtils?: ErrorUtils;
expo?: ExpoGlobalObject;
Expand Down
Loading