UNPKG

@lesnoypudge/utils-react

Version:

lesnoypudge's utils-react

8 lines (7 loc) 573 B
import { T } from '@lesnoypudge/types-utils-base/namespace'; import { createContextSelectable } from '..'; import { useContextSelector } from '../../hooks'; export declare namespace createUseContextSelectorHook { type Return<_Value extends T.UnknownRecord> = <_SelectedValue>(selector: useContextSelector.ContextSelectableSelector<_Value, _SelectedValue>) => _SelectedValue; } export declare const createUseContextSelectorHook: <_Value extends T.UnknownRecord>(context: createContextSelectable.ContextSelectable<_Value>) => createUseContextSelectorHook.Return<_Value>;