mirror of
https://github.com/DefectingCat/DefectingCat.github.io
synced 2025-07-15 16:51:37 +00:00
17 lines
314 B
TypeScript
17 lines
314 B
TypeScript
import { create } from 'zustand';
|
|
|
|
interface MainStore {
|
|
modelLoading: boolean;
|
|
toggleLoading: (loaded: boolean) => void;
|
|
}
|
|
|
|
const useStore = create<MainStore>()((set) => ({
|
|
modelLoading: true,
|
|
toggleLoading: (loaded) =>
|
|
set(() => ({
|
|
modelLoading: loaded,
|
|
})),
|
|
}));
|
|
|
|
export default useStore;
|