(initialState)
| 7601 | null !== root && scheduleUpdateOnFiber(root, fiber, 2); |
| 7602 | } |
| 7603 | function mountStateImpl(initialState) { |
| 7604 | var hook = mountWorkInProgressHook(); |
| 7605 | if ("function" === typeof initialState) { |
| 7606 | var initialStateInitializer = initialState; |
| 7607 | initialState = initialStateInitializer(); |
| 7608 | if (shouldDoubleInvokeUserFnsInHooksDEV) { |
| 7609 | setIsStrictModeForDevtools(!0); |
| 7610 | try { |
| 7611 | initialStateInitializer(); |
| 7612 | } finally { |
| 7613 | setIsStrictModeForDevtools(!1); |
| 7614 | } |
| 7615 | } |
| 7616 | } |
| 7617 | hook.memoizedState = hook.baseState = initialState; |
| 7618 | hook.queue = { |
| 7619 | pending: null, |
| 7620 | lanes: 0, |
| 7621 | dispatch: null, |
| 7622 | lastRenderedReducer: basicStateReducer, |
| 7623 | lastRenderedState: initialState |
| 7624 | }; |
| 7625 | return hook; |
| 7626 | } |
| 7627 | function updateOptimisticImpl(hook, current, passthrough, reducer) { |
| 7628 | hook.baseState = passthrough; |
| 7629 | return updateReducerImpl( |
no test coverage detected
searching dependent graphs…