MCPcopy Create free account
hub / github.com/danielstocks/react-sortable / performWorkCatchBlock

Function performWorkCatchBlock

bundle.js:7842–7851  ·  view source on GitHub ↗
(failedWork,boundary,minPriorityLevel,deadline)

Source from the content-addressed store, hash-verified

7840continue loop;}// We've run out of time. Exit.
7841break loop;case NoWork$2:// No work left. We can exit.
7842break loop;default:invariant(false,'Switch statement should be exhuastive. This error is likely caused by a bug in React. Please file an issue.');}}while(true);}function performWorkCatchBlock(failedWork,boundary,minPriorityLevel,deadline){// We're going to restart the error boundary that captured the error.
7843// Conceptually, we're unwinding the stack. We need to unwind the
7844// context stack, too.
7845unwindContexts(failedWork,boundary);// Restart the error boundary using a forked version of
7846// performUnitOfWork that deletes the boundary's children. The entire
7847// failed subree will be unmounted. During the commit phase, a special
7848// lifecycle method is called on the error boundary, which triggers
7849// a re-render.
7850nextUnitOfWork=performFailedUnitOfWork(boundary);// Continue working.
7851workLoop(minPriorityLevel,deadline);}function performWork(minPriorityLevel,deadline){{startWorkLoopTimer();}!!isPerformingWork?invariant(false,'performWork was called recursively. This error is likely caused by a bug in React. Please file an issue.'):void 0;isPerformingWork=true;// The priority context changes during the render phase. We'll need to
7852// reset it at the end.
7853var previousPriorityContext=priorityContext;var didError=false;var error=null;{invokeGuardedCallback$1(null,workLoop,null,minPriorityLevel,deadline);if(hasCaughtError()){didError=true;error=clearCaughtError();}}// An error was thrown during the render phase.
7854while(didError){if(didFatal){// This was a fatal error. Don't attempt to recover from it.

Callers

nothing calls this directly

Calls 3

unwindContextsFunction · 0.85
performFailedUnitOfWorkFunction · 0.85
workLoopFunction · 0.85

Tested by

no test coverage detected