Login One

@lacspace/store vs Zustand

@lacspace/store is a Zustand-style global store built on React's `useSyncExternalStore`, with persistence built in. It gives you the same create-a-store-and-select-from-it model in a zero-dependency package that shares conventions with the rest of the Lacspace React kit.

npm i @lacspace/store
Read the docs
Feature@lacspace/storeZustand
Dependencies·ZeroZero
API style·create(store) + selector hookcreate(store) + selector hook
Built on useSyncExternalStore·YesYes
PersistenceBuilt inVia middleware
SSR-safe·YesYes
Part of one ecosystemYes — pairs with query, hooks, themeStandalone
Licence·Lacspace Free LicenceMIT

The honest verdict

Zustand is excellent and battle-tested. Reach for @lacspace/store when you want that same minimal model plus built-in persistence, from the same toolkit as your hooks and data layer.

Frequently asked

Does @lacspace/store support persistence?

Yes — persistence to storage is built in, so you don't need a separate middleware to keep state across reloads.

Is the API like Zustand?

Yes. You create a store and select slices from it with a hook, the same mental model, in a zero-dependency package.

More comparisons