- create<T>(
key: string,
value?: T,
plugins?: Plugin<T>[],
): () => [T, SetStateAction<T>] Parameters
- key: string
Optional
value: TOptional
plugins: Plugin<T>[]
- A hook function that returns a tuple (Ordered sequence of values) containing the state and a function to set the state.
Creates a store with plugins.
Example