framework: upgrade cordis

This commit is contained in:
undefined committed 2026-04-17 18:03:41 +08:00
1 parent 772cb7837a
commit 6bdac9fe25
24 files changed
+108 -128

No files matched your search

+17 -1
View File
@@ -12,12 +12,14 @@ import { I18nService } from './lib/i18n';
import { Logger } from './logger';
import {
Context, Service, FiberState, Fiber,
Context, Service, FiberState, Fiber, ApiMixin,
} from './context';
// eslint-disable-next-line import/no-duplicates
import { sleep, unwrapExports } from './utils';
import { PRIV } from './model/builtin';
import { getAddons } from './options';
import { TimerService } from '@cordisjs/plugin-timer';
import LoggerService from '@cordisjs/plugin-logger';
import Schema from 'schemastery';
import { isEqual } from 'lodash';
@@ -162,6 +164,20 @@ export class Loader extends Service {
}
}
app.plugin(ApiMixin);
app.plugin(TimerService);
app.plugin(LoggerService, {
console: {
showDiff: false,
showTime: 'dd hh:mm:ss',
label: {
align: 'right',
width: 9,
margin: 1,
},
levels: { default: process.env.DEV ? 3 : 2 },
},
});
app.plugin(I18nService);
app.plugin(Loader);