Skip to content

ref: Rewrite to use optional chaining & add eslint rule #14966

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

Merged
merged 2 commits into from
Jan 10, 2025

Conversation

mydea
Copy link
Member

@mydea mydea commented Jan 9, 2025

This adds an eslint rule to enforce usage of optional chaining, to keep things consistent.

It also fixes remaining places that "violate" this.

@mydea mydea requested review from Lms24, AbhiPrasad and s1gr1d January 9, 2025 17:07
@mydea mydea self-assigned this Jan 9, 2025
@mydea mydea requested review from a team as code owners January 9, 2025 17:07
@mydea mydea requested a review from billyvg January 9, 2025 17:08
@mydea mydea force-pushed the fn/add-optional-chaining-rule branch from 185e180 to 0806740 Compare January 9, 2025 17:10
Copy link
Contributor

github-actions bot commented Jan 9, 2025

size-limit report 📦

Path Size % Change Change
@sentry/browser 23.01 KB -0.27% -63 B 🔽
@sentry/browser - with treeshaking flags 21.68 KB -0.26% -56 B 🔽
@sentry/browser (incl. Tracing) 35.46 KB -0.27% -95 B 🔽
@sentry/browser (incl. Tracing, Replay) 72.23 KB -0.15% -107 B 🔽
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 62.76 KB -0.15% -95 B 🔽
@sentry/browser (incl. Tracing, Replay with Canvas) 76.49 KB -0.14% -102 B 🔽
@sentry/browser (incl. Tracing, Replay, Feedback) 88.5 KB -0.15% -136 B 🔽
@sentry/browser (incl. Feedback) 39.23 KB -0.26% -104 B 🔽
@sentry/browser (incl. sendFeedback) 27.64 KB -0.24% -68 B 🔽
@sentry/browser (incl. FeedbackAsync) 32.41 KB -0.31% -103 B 🔽
@sentry/react 25.7 KB -0.26% -66 B 🔽
@sentry/react (incl. Tracing) 38.23 KB -0.23% -87 B 🔽
@sentry/vue 27.15 KB -0.31% -84 B 🔽
@sentry/vue (incl. Tracing) 37.26 KB -0.29% -109 B 🔽
@sentry/svelte 23.13 KB -0.25% -59 B 🔽
CDN Bundle 24.28 KB -0.3% -73 B 🔽
CDN Bundle (incl. Tracing) 35.75 KB -0.29% -104 B 🔽
CDN Bundle (incl. Tracing, Replay) 70.42 KB -0.12% -85 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) 75.55 KB -0.17% -130 B 🔽
CDN Bundle - uncompressed 70.78 KB -0.51% -367 B 🔽
CDN Bundle (incl. Tracing) - uncompressed 105.93 KB -0.54% -588 B 🔽
CDN Bundle (incl. Tracing, Replay) - uncompressed 216.76 KB -0.36% -780 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 229.29 KB -0.4% -928 B 🔽
@sentry/nextjs (client) 38.35 KB -0.23% -90 B 🔽
@sentry/sveltekit (client) 36 KB -0.25% -91 B 🔽
@sentry/node 161.7 KB -0.05% -73 B 🔽
@sentry/node - without tracing 97.48 KB -0.07% -60 B 🔽
@sentry/aws-serverless 127.34 KB -0.06% -76 B 🔽

View base workflow run

@mydea mydea merged commit de2c1ad into develop Jan 10, 2025
174 checks passed
@mydea mydea deleted the fn/add-optional-chaining-rule branch January 10, 2025 08:10
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