File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ import * as Sentry from '@sentry/react-native';
1010import { ErrorEvent } from '@sentry/core' ;
1111import { isExpoGo } from '../utils/isExpoGo' ;
1212import { LogBox } from 'react-native' ;
13+ import { isWeb } from '../utils/isWeb' ;
1314
1415export {
1516 // Catch any errors thrown by the Layout component.
@@ -56,8 +57,10 @@ Sentry.init({
5657 } ) ,
5758 navigationIntegration ,
5859 Sentry . reactNativeTracingIntegration ( ) ,
59- Sentry . browserReplayIntegration ( ) ,
6060 ) ;
61+ if ( isWeb ( ) ) {
62+ integrations . push ( Sentry . browserReplayIntegration ( ) ) ;
63+ }
6164 return integrations . filter ( i => i . name !== 'Dedupe' ) ;
6265 } ,
6366 enableAutoSessionTracking : true ,
Original file line number Diff line number Diff line change 1+ import { Platform } from 'react-native' ;
2+
3+ export function isWeb ( ) : boolean {
4+ return Platform . OS === 'web' ;
5+ }
You can’t perform that action at this time.
0 commit comments