This release ships with a beta version of our new built-in Expo SDK 50 support,
which replaces the deprecated sentry-expo
package. To learn more,
see the Expo guide.
Features
-
New
@sentry/react-native/expo
Expo config plugin (#3429)const { withSentry } = require('@sentry/react-native/expo'); const config = {...}; module.exports = withSentry(config, { url: 'https://www.sentry.io/', authToken: 'example-token', // Or use SENTRY_AUTH_TOKEN env project: 'project-slug', // Or use SENTRY_PROJECT env organization: 'org-slug', // Or use SENTRY_ORG env });
- And
Sentry.init
inApp.js
import * as Sentry from '@sentry/react-native'; Sentry.init({ dsn: '__DSN__', });
- And
-
New
getSentryExpoConfig
for simple Metro configuration (#3454, #3501, #3514)- This function is a drop in replacement for
getDefaultConfig
fromexpo/metro-config
// const { getDefaultConfig } = require("expo/metro-config"); const { getSentryExpoConfig } = require("@sentry/react-native/metro"); // const config = getDefaultConfig(__dirname); const config = getSentryExpoConfig(config, {});
- This function is a drop in replacement for
-
New
npx sentry-expo-upload-sourcemaps
for simple EAS Update (npx expo export
) source maps upload (#3491, #3510, #3515, #3507)SENTRY_PROJECT=project-slug \ SENTRY_ORG=org-slug \ SENTRY_AUTH_TOKEN=super-secret-token \ npx sentry-expo-upload-sourcemaps dist
Others
- Update
sentry-xcode.sh
scripts with Node modules resolution (#3450)- RN SDK and Sentry CLI are dynamically resolved if override is not supplied
- Resolve Default Integrations based on current platform (#3465)
- Native Integrations are only added if Native Module is available
- Web Integrations only for React Native Web builds
- Remove Native Modules warning from platform where the absence is expected (#3466)
- Add Expo Context information using Expo Native Modules (#3466)
- Errors from InternalBytecode.js are no longer marked as in_app (#3518)
- Fix system node can't be overwritten in
sentry-xcode-debug-files.sh
(#3523)