Releases: getsentry/sentry-react-native
6.16.0
Features
-
Introducing
@sentry/react-native/playground(#4916)The new
withSentryPlaygroundcomponent allows developers to verify
that the SDK is properly configured and reports errors as expected.import * as Sentry from '@sentry/react-native'; import { withSentryPlayground } from '@sentry/react-native/playground'; function App() { return <View>...</View>; } export default withSentryPlayground( Sentry.wrap(App) );
Fixes
6.15.1 (Stable)
7.0.0-beta.0
Upgrading from 6.x to 7.0
Version 7 of the Sentry React Native SDK primarily introduces API cleanup and version support changes based on the Sentry Javascript SDK version 9. This update contains behavioral changes that will not be caught by type checkers, linters, or tests, so we recommend carefully reading through the entire migration guide instead of relying on automatic tooling.
Version 7 of the SDK is compatible with Sentry self-hosted versions 24.4.2 or higher (unchanged from v6). Lower versions may continue to work, but may not support all features.
Major Changes
- Set
{{auto}}ifuser.ip_addressisundefinedandsendDefaultPii: true(#4466) Sentry.captureUserFeedbackremoved, useSentry.captureFeedbackinstead (#4855)
Major Changes from Sentry JS SDK v9
- Exceptions from
captureConsoleIntegrationare now marked as handled: true by default shutdownTimeoutmoved fromcoreto@sentry/react-nativehasTracingEnabledwas renamed tohasSpansEnabled- You can no longer drop spans or return null on
beforeSendSpanhook - Fork
scopeif custom scope is passed tostartSpanManualorstartSpan
Removed types
- TransactionNamingScheme
- Request
- Scope (prefer using the Scope class)
Other removed items.
autoSessionTrackingfrom options.
To enable session tracking, ensure thatenableAutoSessionTrackingis enabled.enableTracing. Instead, settracesSampleRateto a value greater thanzerotoenable tracing,0to keep tracing integrations active without sampling, orundefinedto disable the performance integration.getCurrentHub(),Hub, andgetCurrentHubShim()spanIdfrom propagationcontext- metrics API
transactionContextfromsamplingContext@sentry/utilspackage, the exports were moved to@sentry/core- Standalone
Clientinterface & deprecateBaseClient
Changes
- Use
Replayinterface forbrowserReplayIntegrationreturn type (#4858) - Allow using
browserReplayIntegrationwithoutisWebguard (#4858)- The integration returns noop in non-browser environments
- Use single
encodeUTF8implementation through the SDK (#4885) - Use global
TextEncoder(available with Hermes in React Native 0.74 or higher) to improve envelope encoding performance. (#4874) breadcrumbsIntegrationdisables React Native incompatible options automatically (#4886)- On React Native Web,
browserSessionIntegrationis added whenenableAutoSessionTrackingis set toTrue(#4732) - Change
Cold/Warm App Startspan description toCold/Warm Start(#4636)
Dependencies
6.15.0
Features
-
User Feedback Widget Updates
FeedbackButtonfor easy access to the widget (#4378)ScreenshotButtonfor capturing the application visuals (#4714)- Theming support to better align with the application styles (#4677)
Sentry.init({ integrations: [ Sentry.feedbackIntegration({ enableTakeScreenshot: true, // Enables `ScreenshotButton` themeDark: { // Add dark theme styles here }, themeLight: { // Add light theme styles here }, }), ], }); Sentry.showFeedbackButton(); Sentry.hideFeedbackButton();
To learn more visit the documentation.
-
Re-export
ErrorEventandTransactionEventtypes (#4859)
Fixes
- crashedLastRun now returns the correct value (#4829)
- Use engine-specific promise rejection tracking (#4826)
- Fixes Feedback Widget accessibility issue on iOS (#4739)
- Measuring TTID or TTFD could cause a crash when
parentSpanIdwas removed (#4881)
Dependencies
6.14.0
Fixes
- Expo Updates Context is passed to native after native init to be available for crashes (#4808)
- Expo Updates Context values should all be lowercase (#4809)
- Avoid duplicate network requests (fetch, xhr) by default (#4816)
traceFetchis disabled by default on mobile as RN uses a polyfill which will be traced bytraceXHR
Changes
- Renames
enableExperimentalViewRenderertoenableViewRendererV2which is enabled by default for up to 5x times more performance in Session Replay on iOS (#4815)
Dependencies
7.0.0-alpha.0
Upgrading from 6.x to 7.0
Version 7 of the Sentry React Native SDK primarily introduces API cleanup and version support changes based on the Sentry Javascript SDK version 9. This update contains behavioral changes that will not be caught by type checkers, linters, or tests, so we recommend carefully reading through the entire migration guide instead of relying on automatic tooling.
Version 7 of the SDK is compatible with Sentry self-hosted versions 24.4.2 or higher (unchanged from v6). Lower versions may continue to work, but may not support all features.
Fixes
- Expo Updates Context is passed to native after native init to be available for crashes (#4808)
- Expo Updates Context values should all be lowercase (#4809)
- Avoid duplicate network requests (fetch, xhr) by default (#4816)
traceFetchis disabled by default on mobile as RN uses a polyfill which will be traced bytraceXHR
Major Changes
- Set
{{auto}}ifuser.ip_addressisundefinedandsendDefaultPii: true(#4466) - Exceptions from
captureConsoleIntegrationare now marked as handled: true by default shutdownTimeoutmoved fromcoreto@sentry/react-nativehasTracingEnabledwas renamed tohasSpansEnabled- You can no longer drop spans or return null on
beforeSendSpanhook
Removed types
- TransactionNamingScheme
- Request
- Scope (prefer using the Scope class)
Other removed items.
autoSessionTrackingfrom options.
To enable session tracking, ensure thatenableAutoSessionTrackingis enabled.enableTracing. Instead, settracesSampleRateto a value greater thanzerotoenable tracing,0to keep tracing integrations active without sampling, orundefinedto disable the performance integration.getCurrentHub(),Hub, andgetCurrentHubShim()spanIdfrom propagationcontext- metrics API
transactionContextfromsamplingContext@sentry/utilspackage, the exports were moved to@sentry/core- Standalone
Clientinterface & deprecateBaseClient
Other Changes
- Fork
scopeif custom scope is passed tostartSpanManualorstartSpan - On React Native Web,
browserSessionIntegrationis added whenenableAutoSessionTrackingis set toTrue(#4732)
ChangeCold/Warm App Startspan description toCold/Warm Start(#4636)
Dependencies
6.13.1 (Stable)
6.13.0
6.12.0
6.11.0
Features
-
Add
createTimeToInitialDisplay({useFocusEffect})andcreateTimeToFullDisplay({useFocusEffect})to allow record full display on screen focus (#4665) -
Add support for measuring Time to Initial Display for already seen routes (#4661)
- Introduce
enableTimeToInitialDisplayForPreloadedRoutesoption to the React Navigation integration.
Sentry.reactNavigationIntegration({ enableTimeToInitialDisplayForPreloadedRoutes: true, });
- Introduce
-
Add
useDispatchedActionDataoption to the React Navigation integration to filter out navigation actions that should not create spans (#4684)- For example
PRELOAD,SET_PARAMS,TOGGLE_DRAWERand others.
Sentry.reactNavigationIntegration({ useDispatchedActionData: true, });
- For example
Fixes
- Equalize TTID and TTFD duration when TTFD manual API is called and resolved before auto TTID (#4680)
- Avoid loading Sentry native components in Expo Go (#4696)
- Avoid silent failure when JS bundle was not created due to Sentry Xcode scripts failure (#4690)
- Prevent crash on iOS during profiling stop when debug images are missing (#4738)
- Attach only App Starts within the 60s threshold (fixed comparison units, use ms) (#4746)
- Add missing
popTimeToDisplayForin to the Android Old Arch Native interface(#4751)
Changes
- Change
gradle.projectsEvaluatedtoproject.afterEvaluatein the Sentry Gradle Plugin to fix tasks not being created when using--configure-on-demand(#4687) - Remove
SENTRY_FORCE_FOREGROUNDfrom Xcode Scripts as the underlying--force-foregroundSentry CLI is no-op since v2.37.0 (#4689) - TTID and TTFD use native getters instead od events to pass timestamps to the JS layer (#4669, #4681)