Skip to content

useWindowFocus ​

elements
test coverage
Last changed: last month

Hook that provides the current focus state of the window

typescript
import { useWindowFocus } from '@siberiacancode/reactuse';

Usage ​

typescript
const focused = useWindowFocus();

Demo ​

Api ​

Returns

boolean

Source ​

Source • Demo

Contributors ​

Avatardebabin

Released under the MIT License.