admin-vben5/apps/web-antd/src/store/index.ts

17 lines
418 B
TypeScript
Raw Normal View History

2024-06-01 23:15:29 +08:00
import type { InitStoreOptions } from '@vben-core/stores';
import type { App } from 'vue';
import { initStore, useAccessStore, useTabbarStore } from '@vben-core/stores';
2024-06-08 19:49:06 +08:00
2024-06-01 23:15:29 +08:00
/**
* @zh_CN pinia
* @param app vue app
*/
async function setupStore(app: App, options: InitStoreOptions) {
const pinia = await initStore(options);
app.use(pinia);
}
export { setupStore, useAccessStore, useTabbarStore };