Zustand · Concept
equality function
createWithEqualityFn makes a React store hook like create, but lets you set a default equality check. The check can prevent re-renders when selected data has not meaningfully changed.
Last updated
Syntax
const useSomeStore = createWithEqualityFn(stateCreatorFn, defaultEqualityFn)In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
createcreateStoreshallowuseStoreuseStoreWithEqualityFnuseShallow