We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b2cff47 commit b7a663cCopy full SHA for b7a663c
packages/react-reconciler/src/ReactFiber.js
@@ -532,10 +532,10 @@ export function createHostRootFiber(
532
mode = NoMode;
533
}
534
535
- if (enableProfilerTimer && isDevToolsPresent) {
536
- // Always collect profile timings when DevTools are present.
537
- // This enables DevTools to start capturing timing at any point–
538
- // Without some nodes in the tree having empty base times.
+ if (__DEV__ || (enableProfilerTimer && isDevToolsPresent)) {
+ // dev: Enable profiling instrumentation by default.
+ // profile: enabled if DevTools is present or subtree is wrapped in <Profiler>.
+ // production: disabled.
539
mode |= ProfileMode;
540
541
0 commit comments