chore: 调整加载接口

This commit is contained in:
AncTe committed 2026-10-14 20:41:14 +08:00
1 parent 2f3d3387a0
commit d1ebca0b16
3 files changed
+4 -7

No files matched your search

+2 -5
View File
@@ -22,14 +22,11 @@ export function createCoreStateConfig(
}
/**
* 创建数据端主对象,返回经过初始化的主对象实例
* 创建数据端主对象,返回未经过初始化的主对象实例,需要手动调用 `state.load` 初始化
* @param starter 加载启动器
*/
export async function createCoreState(
starter: ILoadTaskStarter
): Promise<ICoreState> {
export function createCoreState(starter: ILoadTaskStarter): ICoreState {
const config = createCoreStateConfig(starter);
const state = new CoreState(config);
await state.load();
return state;
}