import { create } from "zustand";

type ContestRefreshStore = {
  refreshKey: number;
  triggerRefresh: () => void;
};

export const useContestRefreshStore = create<ContestRefreshStore>((set) => ({
  refreshKey: 0,
  triggerRefresh: () =>
    set((s) => ({ refreshKey: s.refreshKey + 1 })),
}));
