mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
4e6493a6c1c44c01beb3b376760cb96b151ea99e
`delete` causes an object (in V8, and maybe other engines) to deopt to a dictionary instead of a class. Instead of `assign` + `delete`, manually iterate over all the properties, like the JSX runtime does. To avoid copying the object twice I moved the `ref` prop removal to come before handling default props. If we already cloned the props to remove `ref`, then we can skip cloning again to handle default props. DiffTrain build for commit https://github.com/facebook/react/commit/bfd8da807c75a2d123627415f9eaf2d36ac3ed6a.
react-fbsource-import
Description
Languages
JavaScript
67.1%
TypeScript
29.4%
HTML
1.5%
CSS
1.1%
C++
0.6%
Other
0.2%