Skip to content

Commit a27ad7a

Browse files
committed
perf: avoid creating mismatched maps
1 parent 1293047 commit a27ad7a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

packages/react-reconciler/src/ReactFiberHooks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3489,8 +3489,8 @@ export const ContextOnlyDispatcher: Dispatcher = {
34893489
useContext: throwInvalidHookError,
34903490
useEffect: throwInvalidHookError,
34913491
useImperativeHandle: throwInvalidHookError,
3492-
useInsertionEffect: throwInvalidHookError,
34933492
useLayoutEffect: throwInvalidHookError,
3493+
useInsertionEffect: throwInvalidHookError,
34943494
useMemo: throwInvalidHookError,
34953495
useReducer: throwInvalidHookError,
34963496
useRef: throwInvalidHookError,

packages/react-reconciler/src/ReactFiberHostContext.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@ const hostTransitionProviderCursor: StackCursor<Fiber | null> =
4646
// inside useHostTransitionStatus.
4747
export const HostTransitionContext: ReactContext<TransitionStatus | null> = {
4848
$$typeof: REACT_CONTEXT_TYPE,
49+
Provider: (null: any),
50+
Consumer: (null: any),
4951
_currentValue: null,
5052
_currentValue2: null,
5153
_threadCount: 0,
52-
Provider: (null: any),
53-
Consumer: (null: any),
5454
};
5555

5656
function requiredContext<Value>(c: Value | null): Value {

0 commit comments

Comments
 (0)