Skip to content

Move the Error creation to be lazy #24728

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 1 commit into from
Jun 15, 2022

Conversation

sebmarkbage
Copy link
Collaborator

Creating an Error captures a stack trace which can be somewhat expensive. We shouldn't do that twice for every render.

This also ensures that the stack trace is more useful because you can follow through the Node.js code to see the cause.

Creating an Error captures a stack trace which can be somewhat expensive.
We shouldn't do tthat always for every render.

This also ensures that the stack trace is more useful because you can
follow through the Node.js code to see the cause.
@sizebot
Copy link

sizebot commented Jun 14, 2022

Comparing: 256aefb...938a702

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.min.js = 131.76 kB 131.76 kB = 42.31 kB 42.31 kB
oss-experimental/react-dom/cjs/react-dom.production.min.js = 137.03 kB 137.03 kB = 43.90 kB 43.90 kB
facebook-www/ReactDOM-prod.classic.js = 440.91 kB 440.91 kB = 80.63 kB 80.63 kB
facebook-www/ReactDOM-prod.modern.js = 426.21 kB 426.21 kB = 78.44 kB 78.44 kB
facebook-www/ReactDOMForked-prod.classic.js = 441.61 kB 441.61 kB = 80.85 kB 80.85 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 938a702

@sebmarkbage sebmarkbage merged commit 522f473 into facebook:main Jun 15, 2022
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.

4 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy