MCPcopy Create free account
hub / github.com/esengine/esengine / _loadNpm

Method _loadNpm

packages/runtime-core/src/PluginLoader.ts:277–282  ·  view source on GitHub ↗
(config: PluginLoadConfig)

Source from the content-addressed store, hash-verified

275 }
276
277 private async _loadNpm(config: PluginLoadConfig): Promise<IRuntimePlugin | null> {
278 const module = await import(/* @vite-ignore */ config.packageId);
279 const exportName = config.exportName || 'default';
280 const plugin = module[exportName] as IRuntimePlugin;
281 return plugin?.manifest ? plugin : null;
282 }
283
284 private async _loadLocal(config: PluginLoadConfig): Promise<IRuntimePlugin | null> {
285 if (!config.localPath) {

Callers 1

_loadOneMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected