@sentry/react-native
Advanced tools
Changelog
6.0.0-rc.0
This is a release candidate version of the next major version of the Sentry React Native SDK 6.0.0. This version includes all the changes from the previous 6.0.0-beta.0 and the latest 5.33.1 version.
SENTRY_FORCE_FOREGROUND=false
for background uploadChangelog
5.33.1
This is re-release of 5.33.0 with no changes to ensure that 5.33.1 is tagged as latest release on npmjs.com
Changelog
5.33.0
Add an option to disable native (iOS and Android) profiling for the HermesProfiling
integration (#4094)
To disable native profilers add the hermesProfilingIntegration
.
import * as Sentry from '@sentry/react-native';
Sentry.init({
integrations: [
Sentry.hermesProfilingIntegration({ platformProfilers: false }),
],
});
Changelog
5.24.2
Add an option to disable native (iOS and Android) profiling for the HermesProfiling
integration (#4094)
To disable native profilers add the hermesProfilingIntegration
.
import * as Sentry from '@sentry/react-native';
Sentry.init({
integrations: [
Sentry.hermesProfilingIntegration({ platformProfilers: false }),
],
});
Changelog
6.0.0-beta.1
sentry.origin
to SDK spans to indicated if spans are created by a part of the SDK or manually (#4066)parentSpanIsAlwaysRootSpan
to true
to make parent of network requests predictable (#4084)enableSpotlight
and spotlightSidecarUrl
(#4086)tracePropagationTargets
defaults to all targets on mobile and same origin on the web (#4083)_experiments.profilesSampleRate
to profilesSampleRate
root options object #3851)Changelog
5.32.0
Exclude Sentry Web Replay, reducing the code in 130KB. (#4006)
includeWebReplay
to true
in your metro config as shown in the snippet:// For Expo
const { getSentryExpoConfig } = require("@sentry/react-native/metro");
const config = getSentryExpoConfig(__dirname, { includeWebReplay: true });
// For RN
const { getDefaultConfig } = require('@react-native/metro-config');
const { withSentryConfig } = require('@sentry/react-native/metro');
module.exports = withSentryConfig(getDefaultConfig(__dirname), { includeWebReplay: true });
new ReactNativeTracing
to reactNativeTracingIntegration()
new ReactNavigationInstrumentation
to reactNativeTracingIntegration()
.new ReactNativeNavigationInstrumentation
to reactNativeTracingIntegration()
.ReactNavigationV4Instrumentation
won't be supported in the next major SDK version, upgrade to react-navigation@5
or newer.RoutingInstrumentation
and RoutingInstrumentationInstance
replace by Integration
interface from @sentry/types
.enableAppStartTracking
, enableNativeFramesTracking
, enableStallTracking
, enableUserInteractionTracing
moved to Sentry.init({})
root options.Changelog
6.0.0-beta.0
This is a beta version of the next major version of the Sentry React Native SDK 6.0.0. Please, read the changes listed below as well as the changes made in the underlying Sentry Javascript SDK 8.0.0 (JS Docs).
React Native Tracing options were moved to the root options
import * as Sentry from '@sentry/react-native';
Sentry.init({
tracesSampleRate: 1.0,
enableAppStartTracking: true, // default true
enableNativeFramesTracking: true, // default true
enableStallTracking: true, // default true
enableUserInteractionTracing: true, // default false
integrations: [
Sentry.reactNativeTracingIntegration({
beforeStartSpan: (startSpanOptions) => {
startSpanOptions.name = 'New Name';
return startSpanOptions;
},
}),
Sentry.appStartIntegration({
standalone: false, // default false
}),
],
});
New React Navigation Integration interface (#4003)
import * as Sentry from '@sentry/react-native';
import { NavigationContainer } from '@react-navigation/native';
const reactNavigationIntegration = Sentry.reactNavigationIntegration();
Sentry.init({
tracesSampleRate: 1.0,
integrations: [reactNavigationIntegration],
});
function RootComponent() {
const navigation = React.useRef(null);
return <NavigationContainer ref={navigation}
onReady={() => {
reactNavigationIntegration.registerNavigationContainer(navigation);
}}>
</NavigationContainer>;
}
Removed beforeNavigate
use beforeStartSpan
instead (#3998)
beforeStartSpan
is executed before the span start, compared to beforeNavigate
which was executed before the navigation ended (after the span was created)Native Frames uses spanId
to attach frames replacing traceId
(#4030)
Removed deprecated ReactNativeTracing option idleTimeout
use idleTimeoutMs
instead (#3998)
Removed deprecated ReactNativeTracing option maxTransactionDuration
use finalTimeoutMs
instead (#3998)
New Native Frames Integration (#3996)
New Stall Tracking Integration (#3997)
New User Interaction Tracing Integration (#3999)
New App Start Integration (#3852)
New React Native Navigation Integration interface (#4003)
import * as Sentry from '@sentry/react-native';
import { Navigation } from 'react-native-navigation';
Sentry.init({
tracesSampleRate: 1.0,
integrations: [
Sentry.reactNativeNavigationIntegration({ navigation: Navigation })
],
});