Domains and Layering
How zudo-composer divides authoring responsibilities across its domains and layers.
Five authoring domains
zudo-composer owns the authoring tool. A host supplies a component pack and owns the compositions, content, mappings, sitemaps, and assets the tool saves into its directories. The domain code describes those records and their rules; the feature code turns those rules into editors.
| Domain and source | Responsibility | Feature mounted by the application |
|---|---|---|
| file: src/composer/ | Versioned component trees, commands, composition records, JSX generation, and reusable templates/patterns. | / mounts ComposerApp from src/. |
| file: src/content/ | Content models, typed field values, entries, graph validation, and publication state. | / mounts ContentRouteContent from src/. |
| file: src/mapping/ | Bindings and projections from Content values into Composition fields and collection slots. | / mounts MappingRouteContent from src/. |
| file: src/sitemapper/ | Page trees, route/navigation resolution, and provider-qualified Composition or Mapping assignments. | / mounts SitemapperRouteContent from src/. |
| file: src/assets/ | Asset metadata, logical folders, immutable versions, reference resolution, and upload/delivery boundaries. | / mounts AssetRouteContent from src/. |
Assets is one of the five authoring products, but it remains a global provider. A SiteProject aggregates the other four domains and captures exact Assets references for a release; it does not embed an Assets provider as a fifth project domain.
Layering and composition
src/main.tsx
+-- /composer/preview --> isolated preview entry + trusted pack
|
+-- other routes --> src/App.tsx
|
+-- src/app/ shell, workspace, dashboard
+-- src/components/ shared UI
|
v
src/features/<domain>/
controllers, editors, route content
|
v
src/<domain>/
model / library / catalog / resolver / storage / ...
|
v
browser file-provider adapters
| same-origin development HTTP
v
plugins/ --> domain Node stores --> host-owned filesThe directory names express responsibilities, not a mandatory identical tree in every domain. model/ defines serializable types and validation; library/ defines record/provider operations; storage/ implements persistence adapters. Specialized subdirectories hold work such as Composer's source/ and reuse/, Mapping's resolver/, and Sitemapper's routes/ and catalog/.
Cross-domain consumers use catalogs and provider interfaces. For example, Sitemapper's createCompositionCatalog lists and resolves records across Composition providers, and createMappingAssignmentCatalog supplies Mapping assignments. The application wires those catalogs to the selected workspace in file:
The component pack is another explicit dependency. Headless validation and generation consume its serializable manifest; preview rendering consumes its trusted runtime entries. See Component Packs and Contract and Storage Engine for those boundaries.
Application routes and the dashboard
file:src/ supplies the navigation rail and topbar. Shared controls live under src/components/.
The / route mounts Dashboard from file:
The exact core authoring route list lives in file:/ mounts the release UI, / renders the current working project, and / renders an activated local release. / is special: src/ selects its iframe entry before importing App, so it does not mount the shell or initialize workspace persistence.