dillon1000/react
Commit
Browse files Prevent performance regression in DEV due to warning arguments (#7461)
* Prevent internal performance regression This only affects Facebook website, not open source version of React. On the Facebook website, we don't have a transform for warnings and invariants. Therefore, expensive arguments will be calculated even if the warning doesn't fire. This fixes a few cases where that calculation might be more expensive than usually. In my testing, this brings down average row click time in Power Editor from ~300ms to ~220ms in __DEV__ (vs ~40ms in prod). * Put warning() that shows up in profile behind condition
Changed paths7 files
First-parent comparisonsrc/isomorphic/classic/element/ReactElementValidator.js ModifiedM src/renderers/dom/client/wrappers/ReactDOMSelect.js ModifiedM src/renderers/dom/shared/hooks/ReactDOMUnknownPropertyHook.js ModifiedM src/renderers/shared/ReactDebugTool.js ModifiedM src/renderers/shared/hooks/ReactChildrenMutationWarningHook.js ModifiedM src/renderers/shared/stack/reconciler/ReactChildReconciler.js ModifiedM src/shared/utils/flattenChildren.js ModifiedPatch
Files changed
Rendering syntax-highlighted changes…