fix: plugin context, enhancePluginContextHook not working

This commit is contained in:
JackLian 2022-12-09 11:19:52 +08:00 committed by 刘菊萍(絮黎)
parent 335314aec6
commit f6feef218a
2 changed files with 4 additions and 4 deletions

View File

@ -60,5 +60,6 @@
},
"resolutions": {
"@builder/babel-preset-ice": "1.0.1"
}
}
},
"repository": "git@github.com:alibaba/lowcode-engine.git"
}

View File

@ -41,6 +41,7 @@ export default class PluginContext implements ILowCodePluginContext, ILowCodePlu
options: IPluginContextOptions,
contextApiAssembler: ILowCodePluginContextApiAssembler,
) {
contextApiAssembler.assembleApis(this);
this.plugins = plugins;
const { pluginName = 'anonymous' } = options;
this.logger = getLogger({ level: 'warn', bizName: `designer:plugin:${pluginName}` });
@ -49,8 +50,6 @@ export default class PluginContext implements ILowCodePluginContext, ILowCodePlu
if (enhancePluginContextHook) {
enhancePluginContextHook(this);
}
contextApiAssembler.assembleApis(this);
}
setPreference(