errorStore.ts 274 B

1234567891011
  1. import { create } from 'zustand';
  2. interface ErrorState {
  3. isErrorShown: boolean;
  4. setErrorShown: (shown: boolean) => void;
  5. }
  6. export const useErrorStore = create<ErrorState>((set) => ({
  7. isErrorShown: false,
  8. setErrorShown: (shown) => set({ isErrorShown: shown })
  9. }));