@itwin/core-frontend
Version:
iTwin.js frontend components
21 lines • 680 B
JavaScript
/**
* Implements a "local" extension via LocalExtensionProps.
* An extension is not loaded until it is added to the ExtensionAdmin.
* The execute() and getManifest() methods are used by the ExtensionAdmin.
* @alpha
*/
export class LocalExtensionProvider {
_props;
constructor(_props) {
this._props = _props;
}
/** returns the manifest (package.json) of a local extension */
async getManifest() {
return this._props.manifestPromise;
}
/** executes the javascript main file / bundle (index.js) of a local extension */
async execute() {
return this._props.main();
}
}
//# sourceMappingURL=LocalExtensionProvider.js.map