(shouldPause: boolean)
| 22 | useSyncExternalStore(subscribe, getIsPaused, () => false); |
| 23 | |
| 24 | export const usePauseBootPopups = (shouldPause: boolean): void => { |
| 25 | useEffect(() => { |
| 26 | if (!shouldPause) { |
| 27 | return undefined; |
| 28 | } |
| 29 | |
| 30 | const pauser = Symbol('bootPopupsPauser'); |
| 31 | pausers.add(pauser); |
| 32 | notify(); |
| 33 | |
| 34 | return () => { |
| 35 | pausers.delete(pauser); |
| 36 | notify(); |
| 37 | }; |
| 38 | }, [shouldPause]); |
| 39 | }; |
no test coverage detected