-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
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
chore: disallow optional chaining #10919
Conversation
Size ReportBundles
Usages
|
But after minification it is not that verbose: https://esbuild.github.io/try/#dAAwLjIxLjQALS10YXJnZXQ9ZXMyMDE2IC0tbWluaWZ5AGE/LmI |
See #4882 (comment) |
const root = instance?.subTree | ||
if ( | ||
vnode === root || | ||
// eslint-disable-next-line no-restricted-syntax |
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.
hydration code actually runs in the browser and shouldn't have been allowed
Disallow the use of optional chaining (
a?.b
,a?.()
), except when running on Node.js.