-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
feat(nextjs): Add options to disable webpack plugin #3771
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(nextjs): Add options to disable webpack plugin #3771
Conversation
size-limit report
|
| // do we even want to do this? | ||
| }); | ||
|
|
||
| it('allows SentryWebpackPlugin to be turned off for client code (independent of server code)', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Taking some time to think about this, the tests for constructWebpackConfigFunction should just be a table test, where we pass in different permutations of the config and assert on the return value. We can do this in another PR though.
54e8cd5 to
f7460d9
Compare
AbhiPrasad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reminder: We need to add a task to add this new option to the docs.
Precisely why It's still in draft mode! 🙂
|
Add docs for the options introduced in getsentry/sentry-javascript#3771, which allow the user to disable the addition of `SentryWebpackPlugin` to server and client builds.
Despite our strong encouragement, not everyone wants to use the
SentryWebpackPluginto upload sourcemaps. This PR introduces two new options,disableServerWebpackPluginanddisableClientWebpackPlugin, which can be used innext.config.jslike this:Setting either of these options does two things in the relevant (server or client) config:
webpack.devtoolto besource-mapin production, andSentryWebpackPluginto the webpack config.These changes are documented in getsentry/sentry-docs#3826.
Fixes #3674
Fixes #3513
Fixes #3553
Fixes #3737