
What is ZenBox?
ZenBox is a modern React state management library that combines the simplicity of Zustand with the reactive patterns of Vue. It provides an intuitive API that feels natural to developers familiar with either framework.
Love Zustand & Vue? Meet ZenBox β€οΈ
π» Zustand's Simplicity
const counter = createStore({ count: 0 });
π Vue-like Developer Experience
const doubled = useComputed(() => counter.value.count * 2);
useWatch(
() => counter.value.count,
(current, prev) => console.log("Count changed from", prev, "to", current)
);
Why Choose ZenBox?
- π Easy to Use - Intuitive API for immediate productivity
- β‘ High Performance - Only re-renders what actually changed
- πͺ TypeScript First - Full type inference out of the box, zero boilerplate
- π― Flexible Architecture - Works for both global and component-level state
- π¦ Lightweight - 100 lines of core code, under 3KB gzipped (without Immer)
Getting Started
We believe ZenBox will transform how you think about React state management.
npm install zenbox
Ready to experience state management that feels like magic? β¨
ZenBox vs Zustand
| Learning Curve | β
Minimal (Vue-friendly) | β
Low |
| Vue-like Reactivity | β
useComputed/useWatch | β Manual handling |
| TypeScript Support | β
Complete auto-inference | β οΈ Manual interface definition |
| State Access | β
Unified store.value interface | β Manual get()/set() |
| Cross-Store Computed | β
Automatic dependency tracking | β οΈ Requires pre-combination |
| Store Scoping | β
Built-in Provider for isolation | β Global by default |
| Immer Integration | β
Built-in support | β οΈ Middleware required |
| Bundle Size | < 3KB gzipped (without Immer) | < 1KB gzipped |
License
MIT License Β© 2025-PRESENT Del Wang