Skip to content

Commit

Permalink
Adding Sentry's replay integration
Browse files Browse the repository at this point in the history
  • Loading branch information
keithamoss committed Aug 12, 2024
1 parent 7aa1ba5 commit 800440b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions public-redesign/src/app/sentry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ export const sentryInit = () => {
// stripBasename,
}),
sentryFeedback,
Sentry.replayIntegration({
maskAllText: true,
blockAllMedia: true,
}),
],

// Set tracesSampleRate to 1.0 to capture 100%
Expand All @@ -39,6 +43,14 @@ export const sentryInit = () => {
// Or however deep you want your Redux state context to be
normalizeDepth: 10,

// 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,

beforeSend(event) {
if (event.exception) {
Sentry.showReportDialog({ eventId: event.event_id });
Expand Down

0 comments on commit 800440b

Please sign in to comment.