Download apps/web/src/stores/sidebarDataStore.ts from hunian003/message: direct link, hf CLI and curl.
- Browser
- Download file 500 Bytes
-
https://huggingface.co/spaces/hunian003/message/resolve/main/apps/web/src/stores/sidebarDataStore.ts
- Command line
-
hf download hf://spaces/hunian003/message/apps/web/src/stores/sidebarDataStore.ts
-
curl -L -o sidebarDataStore.ts https://huggingface.co/spaces/hunian003/message/resolve/main/apps/web/src/stores/sidebarDataStore.ts
500 Bytes
| import { create } from 'zustand'; | |
| import { PluginInfo } from '@typings/plugin'; | |
| interface SidebarDataState { | |
| enabledPlugins: PluginInfo[]; | |
| isLoading: boolean; | |
| setEnabledPlugins: (plugins: PluginInfo[]) => void; | |
| setLoading: (loading: boolean) => void; | |
| } | |
| export const useSidebarDataStore = create<SidebarDataState>((set) => ({ | |
| enabledPlugins: [], | |
| isLoading: false, | |
| setEnabledPlugins: (plugins) => set({ enabledPlugins: plugins }), | |
| setLoading: (isLoading) => set({ isLoading }), | |
| })); |