(newState: boolean)
| 17 | let timeout: any; |
| 18 | let localState: boolean = state; |
| 19 | const set = (newState: boolean) => { |
| 20 | if (mounted) { |
| 21 | localState = newState; |
| 22 | setState(newState); |
| 23 | } |
| 24 | }; |
| 25 | |
| 26 | const onEvent = throttle(50, () => { |
| 27 | if (localState) { |
no test coverage detected