Skip to content

Commit a755f74

Browse files
committed
Use the same destructuring style in scheduler as everywhere else
1 parent 83f839c commit a755f74

File tree

1 file changed

+14
-11
lines changed

1 file changed

+14
-11
lines changed

src/renderers/shared/fiber/ReactFiberScheduler.js

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -67,19 +67,22 @@ type TrappedError = {
6767

6868
module.exports = function<T, P, I, TI, C>(config : HostConfig<T, P, I, TI, C>) {
6969
const hostContext = ReactFiberHostContext();
70+
const { resetHostStacks } = hostContext;
7071
const { beginWork } = ReactFiberBeginWork(config, hostContext, scheduleUpdate);
7172
const { completeWork } = ReactFiberCompleteWork(config, hostContext);
72-
const { commitInsertion, commitDeletion, commitWork, commitLifeCycles } =
73-
ReactFiberCommitWork(config, hostContext, trapError);
74-
75-
const hostScheduleAnimationCallback = config.scheduleAnimationCallback;
76-
const hostScheduleDeferredCallback = config.scheduleDeferredCallback;
77-
const useSyncScheduling = config.useSyncScheduling;
78-
79-
const prepareForCommit = config.prepareForCommit;
80-
const resetAfterCommit = config.resetAfterCommit;
81-
82-
const resetHostStacks = hostContext.resetHostStacks;
73+
const {
74+
commitInsertion,
75+
commitDeletion,
76+
commitWork,
77+
commitLifeCycles,
78+
} = ReactFiberCommitWork(config, hostContext, trapError);
79+
const {
80+
scheduleAnimationCallback: hostScheduleAnimationCallback,
81+
scheduleDeferredCallback: hostScheduleDeferredCallback,
82+
useSyncScheduling,
83+
prepareForCommit,
84+
resetAfterCommit,
85+
} = config;
8386

8487
// The priority level to use when scheduling an update.
8588
let priorityContext : PriorityLevel = useSyncScheduling ?

0 commit comments

Comments
 (0)