Interface: ExtensionBootstrap
Makaio Framework / contracts / ExtensionBootstrap
Interface: ExtensionBootstrap
Section titled “Interface: ExtensionBootstrap”Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:94
Bootstrap capability contributed by an extension.
Participates in project export (discoverExportable + export) and
project import (listImportable + import) workflows.
Properties
Section titled “Properties”discoverExportable
Section titled “discoverExportable”discoverExportable: (
ctx) =>Promise<BootstrapAsset[]>
Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:109
Discover assets available for export from the current project.
Parameters
Section titled “Parameters”Discovery context with bus and project info.
Returns
Section titled “Returns”Promise<BootstrapAsset[]>
Assets that can be exported.
export
Section titled “export”export: (
ctx,asset) =>Promise<string>
Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:116
Export a single asset and return its serialized content.
Parameters
Section titled “Parameters”Export context with bus and project info.
The asset to export.
Returns
Section titled “Returns”Promise<string>
Serialized content string written to the bootstrap folder.
folder
Section titled “folder”folder:
string
Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:96
Subfolder name within .makaio/bootstrap/ for this extension’s assets.
import
Section titled “import”import: (
ctx,asset,content,action) =>Promise<BootstrapImportResult>
Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:125
Import a single asset from its serialized content.
Parameters
Section titled “Parameters”Import context with bus, project, and bootstrap folder path.
The asset being imported.
content
Section titled “content”string
Serialized content string from the bootstrap folder.
action
Section titled “action”"replace" | "skip"
User-selected conflict resolution action.
Returns
Section titled “Returns”Promise<BootstrapImportResult>
Result of the import operation.
listImportable
Section titled “listImportable”listImportable: (
ctx,files) =>Promise<BootstrapAsset[]>
Defined in: ../../../packages/contracts/src/extension/contributions/bootstrap-types.ts:103
List assets that can be imported from the bootstrap folder.
Parameters
Section titled “Parameters”Import context with bus, project, and bootstrap folder path.
string[]
Files present in the bootstrap folder.
Returns
Section titled “Returns”Promise<BootstrapAsset[]>
Assets available for import.