fix: 提升管理端启动与导航稳定性

- 等待初始路由就绪并提供可恢复的启动失败页面

- 收敛失效登录导航并按需加载 SVG 图标资源
This commit is contained in:
2026-07-24 19:02:28 +08:00
parent a75f7baf1b
commit da59c713f9
12 changed files with 259 additions and 13 deletions

View File

@@ -1,10 +1,19 @@
/* eslint-disable perfectionist/sort-imports -- 兼容层必须先于所有业务依赖执行。 */
import './polyfills';
import './startup-error.css';
import {initPreferences, preferences, updatePreferences,} from '@easyflow/preferences';
import {unmountGlobalLoading} from '@easyflow/utils';
import {
initPreferences,
preferences,
updatePreferences,
} from '@easyflow/preferences';
import { unmountGlobalLoading } from '@easyflow/utils';
import {normalizeBrandAssetPreferences, overridesPreferences,} from './preferences';
import {
normalizeBrandAssetPreferences,
overridesPreferences,
} from './preferences';
import { renderStartupError } from './startup-error';
/**
* 应用初始化完成之后再进行页面加载渲染
@@ -36,4 +45,8 @@ async function initApplication() {
unmountGlobalLoading();
}
initApplication();
initApplication().catch((error) => {
console.error('Application startup failed.', error);
renderStartupError();
unmountGlobalLoading();
});