mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: remove deprecated util global
This commit is contained in:
23 files changed
+9
-80
No files matched your search
@@ -1,7 +1,6 @@
|
||||
const lazyModules = {};
|
||||
const features: Record<string, string | (() => Promise<any>)> = {};
|
||||
export default async function load(name: string) {
|
||||
if (window.node_modules[name]) return window.node_modules[name];
|
||||
if (name === 'echarts') return import('echarts');
|
||||
if (name === 'moment') return import('moment');
|
||||
if (!window.lazyloadMetadata?.[`${name}.lazy.js`]) throw new Error(`Module ${name} not found`);
|
||||
|
||||
Reference in new issue
Block a user