Skip to content

Commit

Permalink
feat: CQDG-832 add sentry use updated integration
Browse files Browse the repository at this point in the history
  • Loading branch information
Francis Lavoie authored and francisl committed Nov 20, 2024
1 parent 4261b08 commit 41cff68
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 41 deletions.
11 changes: 6 additions & 5 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { createRoot } from 'react-dom/client';
import { BrowserRouter } from 'react-router-dom';
import { localStorageIntegration } from '@ferlab/ui/core/utils/sentry/localStorageIntegration';
import * as Sentry from '@sentry/react';
import EnvironmentVariables from 'helpers/EnvVariables';

import { initUserSnap } from 'services/initUsersnap';
import LocalStorageIntegrations from 'services/sentry/localStorageIntegrations';

import App from './App';
import reportWebVitals from './reportWebVitals';
Expand All @@ -22,12 +22,13 @@ const SentryDSN = EnvironmentVariables.configFor('SENTRY_API');

Sentry.init({
dsn: SentryDSN,
// Set 'tracePropagationTargets' to control for which URLs distributed tracing should be enabled
tracePropagationTargets: ['localhost', reactAppWebRoot],
integrations: [
Sentry.browserTracingIntegration(),
Sentry.browserTracingIntegration({
tracePropagationTargets: ['localhost', reactAppWebRoot],
}),
Sentry.contextLinesIntegration(),
Sentry.browserProfilingIntegration(),
new LocalStorageIntegrations('LocalStorage'),
localStorageIntegration('LocalStorage'),
],
// Performance Monitoring
tracesSampleRate: 1.0, // Capture 100% of the transactions
Expand Down
36 changes: 0 additions & 36 deletions src/services/sentry/localStorageIntegrations.ts

This file was deleted.

0 comments on commit 41cff68

Please sign in to comment.