diff --git a/samples/react-native/ios/sentryreactnativesample/AppDelegate.mm b/samples/react-native/ios/sentryreactnativesample/AppDelegate.mm index fa061be54c..08e8f79765 100644 --- a/samples/react-native/ios/sentryreactnativesample/AppDelegate.mm +++ b/samples/react-native/ios/sentryreactnativesample/AppDelegate.mm @@ -73,9 +73,10 @@ - (BOOL)concurrentRootEnabled return nullptr; } -- (BOOL) shouldStartSentry { - NSArray* arguments = [[NSProcessInfo processInfo] arguments]; - return ![arguments containsObject:@"--sentry-disable-native-start"]; +- (BOOL)shouldStartSentry +{ + NSArray *arguments = [[NSProcessInfo processInfo] arguments]; + return ![arguments containsObject:@"--sentry-disable-native-start"]; } @end diff --git a/samples/react-native/sentry.options.json b/samples/react-native/sentry.options.json index f6465b7923..53ae525bc0 100644 --- a/samples/react-native/sentry.options.json +++ b/samples/react-native/sentry.options.json @@ -11,8 +11,6 @@ "attachScreenshot": true, "attachViewHierarchy": true, "enableCaptureFailedRequests": true, - "_release": "myapp@1.2.3+1", - "_dist": 1, "profilesSampleRate": 1.0, "replaysSessionSampleRate": 1.0, "replaysOnErrorSampleRate": 1.0, diff --git a/samples/react-native/src/App.tsx b/samples/react-native/src/App.tsx index d84f1b9470..02b4fd2827 100644 --- a/samples/react-native/src/App.tsx +++ b/samples/react-native/src/App.tsx @@ -17,7 +17,6 @@ import Animated, { // Import the Sentry React Native SDK import * as Sentry from '@sentry/react-native'; -import { SENTRY_INTERNAL_DSN } from './dsn'; import ErrorsScreen from './Screens/ErrorsScreen'; import PerformanceScreen from './Screens/PerformanceScreen'; import TrackerScreen from './Screens/TrackerScreen'; @@ -55,10 +54,6 @@ const reactNavigationIntegration = Sentry.reactNavigationIntegration({ }); Sentry.init({ - // Replace the example DSN below with your own DSN: - dsn: SENTRY_INTERNAL_DSN, - debug: true, - environment: 'dev', beforeSend: (event: ErrorEvent) => { logWithoutTracing('Event beforeSend:', event.event_id); return event; @@ -74,7 +69,6 @@ Sentry.init({ didCallNativeInit, ); }, - enableUserInteractionTracing: true, integrations(integrations) { integrations.push( reactNavigationIntegration, @@ -110,30 +104,7 @@ Sentry.init({ ); return integrations.filter(i => i.name !== 'Dedupe'); }, - enableAutoSessionTracking: true, - // For testing, session close when 5 seconds (instead of the default 30) in the background. - sessionTrackingIntervalMillis: 30000, - // This will capture ALL TRACES and likely use up all your quota - enableTracing: true, - tracesSampleRate: 1.0, tracePropagationTargets: ['localhost', /^\//, /^https:\/\//, /^http:\/\//], - attachStacktrace: true, - // Attach screenshots to events. - attachScreenshot: true, - // Attach view hierarchy to events. - attachViewHierarchy: true, - // Enables capture failed requests in JS and native. - enableCaptureFailedRequests: true, - // Sets the `release` and `dist` on Sentry events. Make sure this matches EXACTLY with the values on your sourcemaps - // otherwise they will not work. - // release: 'myapp@1.2.3+1', - // dist: `1`, - profilesSampleRate: 1.0, - replaysSessionSampleRate: 1.0, - replaysOnErrorSampleRate: 1.0, - spotlight: true, - // This should be disabled when manually initializing the native SDK - // Note that options from JS are not passed to the native SDKs when initialized manually // autoInitializeNativeSdk: true, }); diff --git a/samples/react-native/src/dsn.ts b/samples/react-native/src/dsn.ts deleted file mode 100644 index 345276a627..0000000000 --- a/samples/react-native/src/dsn.ts +++ /dev/null @@ -1,8 +0,0 @@ -import * as Sentry from '@sentry/react-native'; - -export const SENTRY_INTERNAL_DSN = - 'https://1df17bd4e543fdb31351dee1768bb679@o447951.ingest.sentry.io/5428561'; - -export const getCurrentDsn = () => { - return Sentry.getCurrentHub().getClient()?.getOptions().dsn; -};