Skip to content
This repository has been archived by the owner on Nov 21, 2024. It is now read-only.

fix: update replay settings to include network details from the api #229

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { hasAcceptedCookies } from '@graasp/sdk';
import pkg from '../package.json';
import Root from './Root';
import {
API_HOST,
APP_VERSION,
GA_MEASUREMENT_ID,
SENTRY_DSN,
Expand All @@ -23,19 +24,24 @@ SentryInit({
dsn: SENTRY_DSN,
integrations: [
new BrowserTracing(),
new Replay({ maskAllText: false, maskAllInputs: false }),
new Replay({
maskAllText: false,
maskAllInputs: false,
// allows to capture details for requests to the api
networkDetailAllowUrls: [API_HOST],
}),
],
release: `${pkg.name}@${APP_VERSION}`,
environment: SENTRY_ENV,
tracesSampleRate: 1.0,
tracesSampleRate: 0.5,

// This sets the sample rate to be 10%. You may want this to be 100% while
// in development and sample at a lower rate in production
replaysSessionSampleRate: 0.1,

// If the entire session is not sampled, use the below sample rate to sample
// sessions when an error occurs.
replaysOnErrorSampleRate: 1.0,
replaysOnErrorSampleRate: 0.5,
});

ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
Expand Down