Skip to content

RuntimeBuilder

Holds every App builder of a built composition and emits the Definition the Runtime executes.

Returned by the build function for a root spec. Each canonical App appears once, however many Apps import it.

readonly apps: Record<string, AppBuilder>

Every App in the composition, keyed by canonical App key.


readonly resolution: AppBuilder<AppBuilderTypes>[]

Apps in resolution order: each App follows the Apps it imports.


readonly root: AppBuilder

The App whose spec was built.


readonly workspaceTemplate: TemplateBuilder

The Workspace Template shared by every App in the composition.

toDefinition(): RuntimeDefinition

Emits the Definition of the whole composition.

RuntimeDefinition

The result is memoized. Building it resolves reverse Relations and Union membership across Apps, and fails when a Relation’s toKey collides with an existing Relation key on a target Template.

When two Relations claim the same key on a target Template.

Definitions and serialization