MCPcopy Create free account
hub / github.com/krasimir/react-in-patterns / stopWorkLoopTimer

Function stopWorkLoopTimer

code/communication/public/app.js:7790–7811  ·  view source on GitHub ↗
(interruptedBy)

Source from the content-addressed store, hash-verified

7788}
7789
7790function stopWorkLoopTimer(interruptedBy) {
7791 if (enableUserTimingAPI) {
7792 if (!supportsUserTiming) {
7793 return;
7794 }
7795 var warning$$1 = null;
7796 if (interruptedBy !== null) {
7797 if (interruptedBy.tag === HostRoot) {
7798 warning$$1 = 'A top-level update interrupted the previous render';
7799 } else {
7800 var componentName = getComponentName(interruptedBy) || 'Unknown';
7801 warning$$1 = 'An update to ' + componentName + ' interrupted the previous render';
7802 }
7803 } else if (commitCountInCurrentWorkLoop > 1) {
7804 warning$$1 = 'There were cascading updates';
7805 }
7806 commitCountInCurrentWorkLoop = 0;
7807 // Pause any measurements until the next loop.
7808 pauseTimers();
7809 endMark('(React Tree Reconciliation)', '(React Tree Reconciliation)', warning$$1);
7810 }
7811}
7812
7813function startCommitTimer() {
7814 if (enableUserTimingAPI) {

Callers 1

renderRootFunction · 0.70

Calls 3

getComponentNameFunction · 0.70
pauseTimersFunction · 0.70
endMarkFunction · 0.70

Tested by

no test coverage detected