提交 | 用户 | age | ||
2f6253 | 1 | import type { App } from 'vue'; |
215d8b | 2 | import { createPinia } from 'pinia'; |
2152b3 | 3 | import { registerPiniaPersistPlugin } from '@/store/plugin/persist'; |
327d71 | 4 | |
215d8b | 5 | const store = createPinia(); |
2152b3 | 6 | registerPiniaPersistPlugin(store); |
e23336 | 7 | |
2f6253 | 8 | export function setupStore(app: App<Element>) { |
陈 | 9 | app.use(store); |
10 | } | |
e23336 | 11 | |
215d8b | 12 | export { store }; |