Frontmatter and Meta Files in Code
- An MDX page can export
frontmatter, merged into its frontmatter and validated by the schema. On a dynamic page, it reads the params asprops. - Meta files can be modules, like
meta.ts. The meta file of a dynamic folder can export a function of the folder's params.
Processed Markdown
- Removed content, like imports, no longer leaves blank lines.
Path params and <show>
- A folder or file named
[name]makes a page for each value listed instaticParamsof its meta file or frontmatter. - Each page is compiled for its params, read as
props, and a file at a static path replaces the page of its value. <show when={...}>shows content on a condition. Conditions on params and inlined env vars are decided before headings, TOC, search and Markdown.- The
defineoption of Remark Show sets the values resolved at build time, like Vite'sdefine, also per page. - Custom sources give a dynamic file
dataAt(), andgetStaticParams()lists its params from any storage.
Remark Show
- The content of a kept
<show>branch joins the content around it, like tab code blocks joining the tab group before the branch.