tasko/hooks/use-pro-modal.ts
2024-02-14 21:30:10 -05:00

13 lines
289 B
TypeScript

import { create } from "zustand";
type ProModalStore = {
isOpen: boolean;
onOpen: () => void;
onClose: () => void;
};
export const useProModal = create<ProModalStore>((set) => ({
isOpen: false,
onOpen: () => set({ isOpen: true }),
onClose: () => set({ isOpen: false }),
}));