Skip to content
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

Use stricter equality check #32295

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

OnlyWick
Copy link
Contributor

@OnlyWick OnlyWick commented Feb 3, 2025

In Fiber node, the default value of stateNode is null, so it's better to use === directly for comparison(Additionally, it avoids implicit type conversion)

this.stateNode = null;

@react-sizebot
Copy link

Comparing: 152bfe3...2c3e4a7

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.js = 6.68 kB 6.68 kB = 1.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 514.52 kB 514.55 kB = 91.76 kB 91.76 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB = 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 557.55 kB 557.58 kB = 99.01 kB 99.01 kB
facebook-www/ReactDOM-prod.classic.js = 596.50 kB 596.54 kB = 104.89 kB 104.88 kB
facebook-www/ReactDOM-prod.modern.js = 586.92 kB 586.95 kB = 103.35 kB 103.35 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 9b7fe7f

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

Successfully merging this pull request may close these issues.

3 participants