Zustand · Type Alias
StoreApi.getInitialState
StoreApi.getInitialState returns the state captured when a Zustand store is created. Use it with set to restore the store, commonly through a reset action.
Last updated
Syntax
createStore<T>()((set, get, store) => ({ ... }))In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
createStorecreateStoreApi.getInitialStatesetStategetStatesubscribe