mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
fix(projects): 修复vertical-mix布局、重构初始化的loading
This commit is contained in:
13
src/main.ts
13
src/main.ts
@ -1,23 +1,16 @@
|
||||
import { createApp } from 'vue';
|
||||
import { setupAssets, setupInitSvgLogo } from '@/plugins';
|
||||
import { setupAssets } from '@/plugins';
|
||||
import { setupRouter } from '@/router';
|
||||
import { setupStore } from '@/store';
|
||||
import AppProvider from './AppProvider.vue';
|
||||
import App from './App.vue';
|
||||
|
||||
async function setupApp() {
|
||||
// 初始化加载的svg logo
|
||||
setupInitSvgLogo('#loadingLogo');
|
||||
|
||||
// 引入静态资源
|
||||
setupAssets();
|
||||
|
||||
// 挂载 appProvider 解决路由守卫,Axios中可使用,LoadingBar,Dialog,Message 等之类组件
|
||||
const appProvider = createApp(AppProvider);
|
||||
setupStore(appProvider);
|
||||
appProvider.mount('#appProvider');
|
||||
|
||||
const app = createApp(App);
|
||||
|
||||
// 挂载pinia状态
|
||||
setupStore(app);
|
||||
|
||||
// 挂载路由
|
||||
|
Reference in New Issue
Block a user