Skip to content

feat(nextjs): Add disableLogger option that automatically tree shakes logger statements#7908

Merged
lforst merged 2 commits intodevelopfrom
lforst-nextjs-logger-tree-shake-utility
Apr 21, 2023
Merged

feat(nextjs): Add disableLogger option that automatically tree shakes logger statements#7908
lforst merged 2 commits intodevelopfrom
lforst-nextjs-logger-tree-shake-utility

Conversation

@lforst
Copy link
Copy Markdown
Contributor

@lforst lforst commented Apr 19, 2023

This is just adding a very convenient way of treeshaking the logger we can put into docs snippets and the wizard.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 19, 2023

size-limit report 📦

Path Size
@sentry/browser - ES5 CDN Bundle (gzipped + minified) 20.98 KB (0%)
@sentry/browser - ES5 CDN Bundle (minified) 65.49 KB (0%)
@sentry/browser - ES6 CDN Bundle (gzipped + minified) 19.52 KB (+0.01% 🔺)
@sentry/browser - ES6 CDN Bundle (minified) 57.95 KB (0%)
@sentry/browser - Webpack (gzipped + minified) 21.12 KB (0%)
@sentry/browser - Webpack (minified) 68.9 KB (0%)
@sentry/react - Webpack (gzipped + minified) 21.14 KB (0%)
@sentry/nextjs Client - Webpack (gzipped + minified) 48.99 KB (0%)
@sentry/browser + @sentry/tracing - ES5 CDN Bundle (gzipped + minified) 28.55 KB (0%)
@sentry/browser + @sentry/tracing - ES6 CDN Bundle (gzipped + minified) 26.78 KB (0%)
@sentry/replay ES6 CDN Bundle (gzipped + minified) 45.35 KB (0%)
@sentry/replay - Webpack (gzipped + minified) 39.28 KB (0%)
@sentry/browser + @sentry/tracing + @sentry/replay - ES6 CDN Bundle (gzipped + minified) 64.23 KB (0%)
@sentry/browser + @sentry/replay - ES6 CDN Bundle (gzipped + minified) 57.2 KB (0%)

@lforst lforst requested a review from AbhiPrasad April 19, 2023 14:50
Copy link
Copy Markdown
Member

@Lms24 Lms24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, we can do the same thing in SvelteKit! (will add a note to the SDK stretch goals)

@Lms24
Copy link
Copy Markdown
Member

Lms24 commented Apr 20, 2023

Also, can/should we do the same for tree-shaking tracing code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants