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

Function ReactFiberScheduler

code/dependency-injection/public/app.js:12776–14110  ·  view source on GitHub ↗
(config)

Source from the content-addressed store, hash-verified

12774}
12775
12776var ReactFiberScheduler = function (config) {
12777 var stack = ReactFiberStack();
12778 var hostContext = ReactFiberHostContext(config, stack);
12779 var legacyContext = ReactFiberLegacyContext(stack);
12780 var newContext = ReactFiberNewContext(stack);
12781 var popHostContext = hostContext.popHostContext,
12782 popHostContainer = hostContext.popHostContainer;
12783 var popTopLevelLegacyContextObject = legacyContext.popTopLevelContextObject,
12784 popLegacyContextProvider = legacyContext.popContextProvider;
12785 var popProvider = newContext.popProvider;
12786
12787 var hydrationContext = ReactFiberHydrationContext(config);
12788
12789 var _ReactFiberBeginWork = ReactFiberBeginWork(config, hostContext, legacyContext, newContext, hydrationContext, scheduleWork, computeExpirationForFiber),
12790 beginWork = _ReactFiberBeginWork.beginWork;
12791
12792 var _ReactFiberCompleteWo = ReactFiberCompleteWork(config, hostContext, legacyContext, newContext, hydrationContext),
12793 completeWork = _ReactFiberCompleteWo.completeWork;
12794
12795 var _ReactFiberUnwindWork = ReactFiberUnwindWork(hostContext, legacyContext, newContext, scheduleWork, isAlreadyFailedLegacyErrorBoundary),
12796 throwException = _ReactFiberUnwindWork.throwException,
12797 unwindWork = _ReactFiberUnwindWork.unwindWork,
12798 unwindInterruptedWork = _ReactFiberUnwindWork.unwindInterruptedWork;
12799
12800 var _ReactFiberCommitWork = ReactFiberCommitWork(config, onCommitPhaseError, scheduleWork, computeExpirationForFiber, markLegacyErrorBoundaryAsFailed, recalculateCurrentTime),
12801 commitResetTextContent = _ReactFiberCommitWork.commitResetTextContent,
12802 commitPlacement = _ReactFiberCommitWork.commitPlacement,
12803 commitDeletion = _ReactFiberCommitWork.commitDeletion,
12804 commitWork = _ReactFiberCommitWork.commitWork,
12805 commitLifeCycles = _ReactFiberCommitWork.commitLifeCycles,
12806 commitErrorLogging = _ReactFiberCommitWork.commitErrorLogging,
12807 commitAttachRef = _ReactFiberCommitWork.commitAttachRef,
12808 commitDetachRef = _ReactFiberCommitWork.commitDetachRef;
12809
12810 var now = config.now,
12811 scheduleDeferredCallback = config.scheduleDeferredCallback,
12812 cancelDeferredCallback = config.cancelDeferredCallback,
12813 prepareForCommit = config.prepareForCommit,
12814 resetAfterCommit = config.resetAfterCommit;
12815
12816 // Represents the current time in ms.
12817
12818 var originalStartTimeMs = now();
12819 var mostRecentCurrentTime = msToExpirationTime(0);
12820 var mostRecentCurrentTimeMs = originalStartTimeMs;
12821
12822 // Used to ensure computeUniqueAsyncExpiration is monotonically increases.
12823 var lastUniqueAsyncExpiration = 0;
12824
12825 // Represents the expiration time that incoming updates should use. (If this
12826 // is NoWork, use the default strategy: async updates in async mode, sync
12827 // updates in sync mode.)
12828 var expirationContext = NoWork;
12829
12830 var isWorking = false;
12831
12832 // The next work in progress fiber that we're currently working on.
12833 var nextUnitOfWork = null;

Callers 1

ReactFiberReconciler$1Function · 0.70

Calls 13

ReactFiberStackFunction · 0.70
ReactFiberHostContextFunction · 0.70
ReactFiberLegacyContextFunction · 0.70
ReactFiberNewContextFunction · 0.70
ReactFiberBeginWorkFunction · 0.70
ReactFiberCompleteWorkFunction · 0.70
ReactFiberUnwindWorkFunction · 0.70
ReactFiberCommitWorkFunction · 0.70
msToExpirationTimeFunction · 0.70
popHostContainerFunction · 0.70
popHostContextFunction · 0.70

Tested by

no test coverage detected