Skip to content

Conversation

@jpreynat
Copy link
Member

@jpreynat jpreynat commented Jun 25, 2024

Noticed that one of the JS chunks for the app was quite big, and it included a whole lot of code dedicated to Sentry only, which we don't use to a lot of extent client-side (no integrations).

Searched and found this GitHub issue, talking about this tree shaking guide.

Applying the suggestions led to removing ~40KB of gzipped code, or ~136KB of uncompressed JS, which is ~10% of the first load JS code size.

Before (main)

image

After

image
@jpreynat jpreynat self-assigned this Jun 25, 2024
@github-actions github-actions bot temporarily deployed to gitbook-open (Preview) June 25, 2024 13:03 Inactive
@argos-ci
Copy link

argos-ci bot commented Jun 25, 2024

The latest updates on your projects. Learn more about Argos notifications ↗︎

Build Status Details Updated (UTC)
default (Inspect) 👍 Changes approved 5 changed Jun 25, 2024, 1:29 PM
@github-actions github-actions bot temporarily deployed to gitbook-open (Preview) June 25, 2024 13:11 Inactive
@github-actions github-actions bot temporarily deployed to gitbook-open (Preview) June 25, 2024 13:25 Inactive
@jpreynat jpreynat marked this pull request as ready for review June 25, 2024 13:38
Copy link
Contributor

@scazan scazan left a comment

Choose a reason for hiding this comment

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

nice improvement!

@jpreynat jpreynat merged commit 97035a0 into main Jun 25, 2024
@jpreynat jpreynat deleted the sentry-tree-shaking branch June 25, 2024 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants