Skip to content

Commit 4a86ec5

Browse files
authored
fix[react-devtools]: removed redundant startProfiling call (#31131)
Stacked on #31118. See last commit. We don't need to call `startProfiling()` here, because we delegate this to the Renderer itself: https://github.com/facebook/react/blob/830e823cd2c6ee675636d31320b10350e8ade9ae/packages/react-devtools-shared/src/backend/fiber/renderer.js#L5227-L5232 Since this is de-facto the constructor of Renderer, this will be called earlier. Validated via testing the reload-to-profile for Chrome browser extension.
1 parent 389a2de commit 4a86ec5

File tree

1 file changed

+0
-4
lines changed
  • packages/react-devtools-shared/src/backend

1 file changed

+0
-4
lines changed

packages/react-devtools-shared/src/backend/agent.js

-4
Original file line numberDiff line numberDiff line change
@@ -714,10 +714,6 @@ export default class Agent extends EventEmitter<{
714714
) {
715715
this._rendererInterfaces[rendererID] = rendererInterface;
716716

717-
if (this._isProfiling) {
718-
rendererInterface.startProfiling(this._recordChangeDescriptions);
719-
}
720-
721717
rendererInterface.setTraceUpdatesEnabled(this._traceUpdatesEnabled);
722718

723719
// When the renderer is attached, we need to tell it whether

0 commit comments

Comments
 (0)