useAsyncFocusBlur<T>

An utility function for asynchronous focus/blur handling.

By default, the onFocus and onBlur callbacks are called every time a child components receives/loses focus. Use this utility hook for scenarios where you need to know if the parent has received focus for the first time, or completely lost focus.

Parameters

_ { onBlur: (event: T) => void; onFocus: (event: T) => void; }

Returns

{ onBlur?: (event: T) => void; onFocus?: (event: T) => void; }