Skip to content

Commit 46e0f84

Browse files
docs(nextjs): Add info on opting out of client/server bundles (#6057)
1 parent 8d80b24 commit 46e0f84

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/platforms/javascript/guides/nextjs/manual-setup.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -429,3 +429,9 @@ const moduleExports = {
429429
Please note that this option will tunnel Sentry events through your Next.js application so you might experience increased server usage.
430430

431431
Learn more about tunneling in the <PlatformLink to="/troubleshooting/#dealing-with-ad-blockers">troubleshooting section</PlatformLink>.
432+
433+
### Opt Out of Sentry SDK bundling in Client or Server side
434+
435+
If you want the `sentry` to be available in your server side & not in client side, you can make your `sentry.client.config.js` empty. This will prevent webpack from pulling in the Sentry related files when generating the browser bundle. The same goes the opposite for opting out of server side bundle by emptying `sentry.server.config.js`.
436+
437+
You cannot delete the respective config files because the SDK requires you to have it.

0 commit comments

Comments
 (0)