mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-17 20:29:42 +02:00
Projects included: - maerchenzauber (NestJS backend + Expo mobile + SvelteKit web + Astro landing) - manacore (Expo mobile + SvelteKit web + Astro landing) - manadeck (NestJS backend + Expo mobile + SvelteKit web) - memoro (Expo mobile + SvelteKit web + Astro landing) This commit preserves the current state before monorepo restructuring. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
15 lines
434 B
TypeScript
15 lines
434 B
TypeScript
import { create } from 'zustand';
|
|
|
|
export interface BearState {
|
|
bears: number;
|
|
increasePopulation: () => void;
|
|
removeAllBears: () => void;
|
|
updateBears: (newBears: number) => void;
|
|
}
|
|
|
|
export const useStore = create<BearState>((set) => ({
|
|
bears: 0,
|
|
increasePopulation: () => set((state) => ({ bears: state.bears + 1 })),
|
|
removeAllBears: () => set({ bears: 0 }),
|
|
updateBears: (newBears) => set({ bears: newBears }),
|
|
}));
|