MCPcopy Index your code
hub / github.com/krasimir/react-in-patterns / ReactFiberScheduler

Function ReactFiberScheduler

code/new-context-api/public/app.js:12044–13378  ·  view source on GitHub ↗
(config)

Source from the content-addressed store, hash-verified

12042}
12043
12044var ReactFiberScheduler = function (config) {
12045 var stack = ReactFiberStack();
12046 var hostContext = ReactFiberHostContext(config, stack);
12047 var legacyContext = ReactFiberLegacyContext(stack);
12048 var newContext = ReactFiberNewContext(stack);
12049 var popHostContext = hostContext.popHostContext,
12050 popHostContainer = hostContext.popHostContainer;
12051 var popTopLevelLegacyContextObject = legacyContext.popTopLevelContextObject,
12052 popLegacyContextProvider = legacyContext.popContextProvider;
12053 var popProvider = newContext.popProvider;
12054
12055 var hydrationContext = ReactFiberHydrationContext(config);
12056
12057 var _ReactFiberBeginWork = ReactFiberBeginWork(config, hostContext, legacyContext, newContext, hydrationContext, scheduleWork, computeExpirationForFiber),
12058 beginWork = _ReactFiberBeginWork.beginWork;
12059
12060 var _ReactFiberCompleteWo = ReactFiberCompleteWork(config, hostContext, legacyContext, newContext, hydrationContext),
12061 completeWork = _ReactFiberCompleteWo.completeWork;
12062
12063 var _ReactFiberUnwindWork = ReactFiberUnwindWork(hostContext, legacyContext, newContext, scheduleWork, isAlreadyFailedLegacyErrorBoundary),
12064 throwException = _ReactFiberUnwindWork.throwException,
12065 unwindWork = _ReactFiberUnwindWork.unwindWork,
12066 unwindInterruptedWork = _ReactFiberUnwindWork.unwindInterruptedWork;
12067
12068 var _ReactFiberCommitWork = ReactFiberCommitWork(config, onCommitPhaseError, scheduleWork, computeExpirationForFiber, markLegacyErrorBoundaryAsFailed, recalculateCurrentTime),
12069 commitResetTextContent = _ReactFiberCommitWork.commitResetTextContent,
12070 commitPlacement = _ReactFiberCommitWork.commitPlacement,
12071 commitDeletion = _ReactFiberCommitWork.commitDeletion,
12072 commitWork = _ReactFiberCommitWork.commitWork,
12073 commitLifeCycles = _ReactFiberCommitWork.commitLifeCycles,
12074 commitErrorLogging = _ReactFiberCommitWork.commitErrorLogging,
12075 commitAttachRef = _ReactFiberCommitWork.commitAttachRef,
12076 commitDetachRef = _ReactFiberCommitWork.commitDetachRef;
12077
12078 var now = config.now,
12079 scheduleDeferredCallback = config.scheduleDeferredCallback,
12080 cancelDeferredCallback = config.cancelDeferredCallback,
12081 prepareForCommit = config.prepareForCommit,
12082 resetAfterCommit = config.resetAfterCommit;
12083
12084 // Represents the current time in ms.
12085
12086 var originalStartTimeMs = now();
12087 var mostRecentCurrentTime = msToExpirationTime(0);
12088 var mostRecentCurrentTimeMs = originalStartTimeMs;
12089
12090 // Used to ensure computeUniqueAsyncExpiration is monotonically increases.
12091 var lastUniqueAsyncExpiration = 0;
12092
12093 // Represents the expiration time that incoming updates should use. (If this
12094 // is NoWork, use the default strategy: async updates in async mode, sync
12095 // updates in sync mode.)
12096 var expirationContext = NoWork;
12097
12098 var isWorking = false;
12099
12100 // The next work in progress fiber that we're currently working on.
12101 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