react-native-mmkv
Version:
⚡️ The fastest key/value storage for React Native.
3 lines (2 loc) • 365 B
TypeScript
import type { MMKV } from '../specs/MMKV.nitro';
export declare function createMMKVHook<T extends (boolean | number | string | ArrayBufferLike) | undefined, TSet extends T | undefined, TSetAction extends TSet | ((current: T) => TSet)>(getter: (instance: MMKV, key: string) => T): (key: string, instance?: MMKV) => [value: T, setValue: (value: TSetAction) => void];