Alpha: Ships on npm at 7.0.0-alpha.07.0.0-alpha.0
Template
Each kind of page is a Template: a Page names one of seven in its template field, and the Template says which Section types it carries.
A Template is reusable Content with variables, filled from Things in the graph and authored as MDX, rendering a Message, Document, or Page.Template startupbuilder.dev
In mdxui, each kind of page is a Template, and a Page names its kind in template. A set of packages styled for one look is a template package, never a Template.
What mdxui renders
The seven Templates, each drawn from a worked Site that uses it. Open one for its Section types in order and a starter record.
template | The page | Section types it carries |
|---|---|---|
api-product | A product landing | nav, hero, the feature and code types, pricing, faq, closing, footer |
article | A reading page, a 404 or terms | article |
blog | A blog index | post-list |
post | One post | page-head, article |
contact | A contact page | cta-form |
directory-list | A directory of products | product-list |
directory-product | One product in a directory | product-head, facts, pricing |
The two directory kinds wear the directory Theme: monochrome, one typeface, a tool rather than a landing.
How it maps
| startupbuilder.dev | mdxui today | Status |
|---|---|---|
rendering a Page | template, one of seven page kinds | Alpha: Renders today from the published packages |
places Components | Slots: which Section type fills each, in order, and how many | Spec: Written ahead of the package |
variables | None: the agent writes every value into the record | Gap: No counterpart in the record; the intended Noun drafts one |
authored as MDX | Authored as JSON, so a page parses or is refused | Gap: No counterpart in the record; the intended Noun drafts one |
rendering a Message | The Email rendering | Spec: Written ahead of the package |
rendering a Document | No Document rendering | Gap: No counterpart in the record; the intended Noun drafts one |
Status
PageSchema accepts the seven ids and checks no slot: a blog page that holds a pricing section parses.
Intended Noun
noun: Template slots
projects: startupbuilder.dev Template, quoted above; the page kinds only
fields:
id: { type: enum, values: [api-product, article, blog, post, contact, directory-list, directory-product], required: true }
slots:
type: list of Slot, in page order, required: true
Slot:
name: { type: string, max: 32, required: true, example: how it works }
fills: { type: list of Section type, count: 1 or more, required: true }
required: { type: boolean, required: true }
count: { type: integer range, example: exactly 4 }
rules: { type: list of cross-slot rules, example: at least one section shows code }
example: api-product
slots: nav, hero with an action, how it works, compare?, product, integration?, provenance?, confidence?, developers?, pricing?, faq, closing with actions, footer with a For agents column