fix: 加载优化
This commit is contained in:
@@ -9,18 +9,26 @@ import store from './stores';
|
||||
import './styles/index.scss';
|
||||
import 'virtual:uno.css';
|
||||
import 'element-plus/dist/index.css';
|
||||
// SVG插件配置
|
||||
import 'virtual:svg-icons-register';
|
||||
|
||||
// 创建 Vue 应用
|
||||
const app = createApp(App);
|
||||
|
||||
// 安装插件
|
||||
app.use(router);
|
||||
app.use(ElMessage);
|
||||
app.use(ElementPlusX);
|
||||
// 注册ElementPlus所有图标
|
||||
|
||||
// 注册图标
|
||||
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
|
||||
app.component(key, component);
|
||||
}
|
||||
|
||||
app.use(store);
|
||||
|
||||
// 挂载 Vue 应用
|
||||
// mount 完成说明应用初始化完毕,此时手动通知 loading 动画结束
|
||||
app.mount('#app');
|
||||
|
||||
// 通知 index.html 的 loading 动画进度拉满并淡出
|
||||
(window as any).finishLoading?.();
|
||||
|
||||
Reference in New Issue
Block a user