Skip to main content

Nesting & Pipeline

Nesting & safety​

Components can use other components. The composer resolves recursively up to 8 levels deep, baking scoped data at each level.

  • Where a use resolves — first among your own workspace's components, then in the platform's published catalog. A component of yours with the same metadata.name takes precedence over the catalog's, and a use never reaches another workspace.
  • Circular detection — the composer tracks visited components; a reference that would repeat one already open (A → B → A) is skipped and reported, and the rest of the document still renders. Past 8 levels, the deeper reference is skipped and reported the same way.
  • One name, several components — when more than one of your components carries the same metadata.name, a pinned version picks the one with that version; without a pin, the highest version wins, and between equal versions the most recently saved. Give each component its own name unless it is a new version of the same one.
  • How many uses — one document may place at most 1,000 components in all, every use counted wherever it sits (an svg symbol and a nested use included); the depth cap bounds how deep they nest, this one how often they are used. The nodes components bring count toward the document's content-node cap, which data binding shares. Past either cap the document is refused with TOO_MANY_COMPONENTS or CONTENT_TOO_LARGE rather than rendered incomplete — see Limits.

Composition pipeline​

  1. The document loads
  2. Every use resolves (recursively, depth-limited) — configuration merges, per-use data is baked in, section styles are stamped, content assembles
  3. Remaining $data / $item tokens resolve with the caller's data
  4. Static globals ($global.DATE, $global.TITLE, …) resolve right after
  5. The document is laid out and the final PDF / DOCX renders; only the page tokens ($global.PAGE, $global.NUMPAGES, $global.SECTION) wait for this step, resolving page by page

Composition runs before the global data pass, so components can carry $data references that resolve with the caller's data.