Skip to content

Commit 3fbcac7

Browse files
committed
fix: hot-fix for capturing exceptions
1 parent 9a4f595 commit 3fbcac7

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

next.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ export default withSentryConfig(
8181
// transpile the Sentry code too since we target older browsers in our .browserslistrc
8282
transpileClientSDK: true,
8383
// attempt to circumvent ad blockers
84-
tunnelRoute: '/monitoring',
84+
tunnelRoute: ENABLE_STATIC_EXPORT ? undefined : '/monitoring',
8585
// prevent source map comments in built files
8686
hideSourceMaps: false,
8787
disableLogger: true,

sentry.client.config.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,9 @@ init({
1111
replaysOnErrorSampleRate: 1.0,
1212
// percentage of sessionsto sample (10%)
1313
replaysSessionSampleRate: 0.1,
14+
// support replaying client sessions to capture unhappy paths
1415
integrations: [new Replay()],
16+
// we only want to capture errors from _next folder on production
17+
// we don't want to capture errors from preview branches here
18+
allowUrls: ['https://nodejs.org/_next'],
1519
});

0 commit comments

Comments
 (0)