Spec: Written ahead of the package. Not in 7.0.0-alpha.0: site, sitemap7.0.0-alpha.0

Site

A Site's Pages, navigation and Brand, rendered as a folder of Page records under one Theme, with its 404, contact and terms pages.

startupbuilder.dev defines
A Site is a website as a Thing: its Pages, navigation, and Brand, served on one or more Domains.
Site startupbuilder.dev

What mdxui renders

A Site is a folder of Page records that all name one Theme, plus a 404 record. Each worked Site below is one, rendered whole by @mdxui/site.

PartComes fromBuilt by
Every Page under the originOne Page record each, all naming one ThemerenderPage per record, or site.ts's render under your own Theme
The header on every PageOne nav section, the same on each Pagethe nav Section type
The footer on every PageOne footer section, the same on each Pagethe footer Section type
A 404 pagepages/harbor/404.json, the article Templateship.ts, as dist/404.html
A contact pagepages/harbor/contact.json, the contact Templatethe cta-form Section type, and worker.ts on /contact/send
A terms pagepages/harbor/terms.json, the article TemplaterenderPage
sitemap.xml and robots.txtThe Pages, less the 404 and any record marked noindexship.ts; @mdxui/site#sitemap, intended
Share imagesOne per Page, from its meta.imagerenderPage writes the tags; the images are drawn by hand, and generated images are intended

How it maps

Site mdxuiAlpha: Renders today from the published packages 5Spec: Written ahead of the package 2Gap: No counterpart in the record; the intended Noun drafts one 2Study: App and View territory: studied, not designed 1Host: The job of the host that serves the files, not of the renderer 1
startupbuilder.devmdxui todayStatus
PagesOne Page record per address, pages/<site>/<path>.json, rendered by renderPageAlpha: Renders today from the published packages
navigationnavfooterA nav and a footer section in each recordAlpha: Renders today from the published packages
BrandThe record's theme: one of five Themes, the same on every PageAlpha: Renders today from the published packages
DomainsThe host serves the files; Ship a Site deploys them to a WorkerHost: The job of the host that serves the files, not of the renderer
sites/[site]/ A folder of JSON records in place of MDX Page filesAlpha: Renders today from the published packages
layout.mdx No shared layout: each record repeats its nav and footer sectionsGap: No counterpart in the record; the intended Noun drafts one
[key]/ routes No Collection route: each member is a record of its ownGap: No counterpart in the record; the intended Noun drafts one
not-found.mdx 404.json, an article record, written as 404.htmlAlpha: Renders today from the published packages
Portal The signed-in part belongs to the App; see App typesStudy: App and View territory: studied, not designed
the whole Site in one callsite({ origin, theme, pages })Spec: Written ahead of the package
sitemap and robotssitemap(pages); Ship a Site writes both by handSpec: Written ahead of the package

Status

Every Page of a Site renders today, one renderPage call per record. A Site renders whole or not at all, so Ship a Site refuses a folder with no 404 record or with a second Theme.

site(), as specified
// path → file: every Page as HTML, then 404.html, sitemap.xml and robots.txt
const files: Map<string, string> = site({ origin, theme, pages });
// theme: a bundled name or a Theme entry, the shape THEMES holds each Theme in
// pages: path → Page record; '/404' and '/terms' are required
// refused: a missing 404 or terms page, or a record under a second Theme

Intended Noun

The record a Site needs, drafted where today's folder of records has a gap: one header, one footer and one logo, written once.

intended Noun: Site record (mdxui.dev namespace)
noun: Site record
projects: startupbuilder.dev Site, quoted above; defines nothing new
fields:
  origin: { type: URL, required: true }
  theme: { type: Theme, required: true, note: one Theme for every Page }
  pages: { type: Page, count: 1 or more, required: true }
  header: { type: section, holds: nav, required: true, note: written once, drawn on every Page }
  footer: { type: section, holds: footer, required: true, note: written once, drawn on every Page }
  logo: { type: SVG asset path, required: false, note: drawn at the brand mark's size in the Theme's ink }
  contact: { type: URL, required: false, note: the address /contact/send forwards to }
  terms: { type: Page, template: article, required: true }
  notFound: { type: Page, template: article, required: true }

On this page