Config API
Every key accepted by the site chrome data files in src/data/, its type, default and effect.
header.json
logoSourcestringrequiredPath to the header logo, an SVG or PNG. Used in both color modes unless
logoAlternateSourceis set.logoAlternateSourcestringPath to the logo shown in dark mode.
logoAltstringAlt text for the logo, usually the site name.
showVersionNumberbooleanBadge beside the brand showing the latest changelog version. Hidden when off or when the changelog has no releases.
topbarLinks{ name, path }[]Links in the header, to the right of the brand. Hidden below 640px.
searchbooleandefault trueShows the search control and binds ⌘K.
searchPlaceholderstringPlaceholder inside the overlay's input.
themeTogglebooleandefault trueShows the light/dark control in the header. The scheme is still resolved without it.
sidebar.json
homeLabelstringdefault "Overview"Label for the standalone link above the first sidebar group.
navGroups{ name, collapsed }[]Sidebar group order. A group used in frontmatter but absent here is appended alphabetically.
pageTools.json
repositoryUrlstringThe site's source repository.
src/utils/repository.tsderives the per-page "Edit this page" link from it; a/tree/<branch>suffix names the branch edit links target, defaulting tomain. Empty hides the link.editPageLabelstringdefault "Edit this page"Text of the edit link.
feedback.enabledbooleandefault trueShows the helpful vote at the foot of every documentation page.
feedback.actionstringdefault ""Where the vote is posted. Empty posts to the page the reader voted on. With CloudCannon Forms, any page on this site also works, such as a thank-you page that readers reach only with JavaScript off. For another service, use its endpoint URL — see Feedback & forms.
feedback.inboxKeystringdefault "stratus-form"The CloudCannon Inbox that receives the votes, sent as a hidden
inbox_keyfield. Every form on this site usesstratus-form. Delete it whenactionpoints at another service.feedback.promptstringdefault "Was this page helpful?"The question beside the vote buttons.
feedback.successMessagestringShown once a reader has voted.
copyPage.enabledbooleandefault trueShows the Copy page menu beside each documentation page's title. A page can opt out with
showCopyPage: falsein its frontmatter.copyPage.labelstringdefault "Copy page"Text on the menu's trigger.
theme.json
The accent and brand colors live here too — see Theming.
defaultTheme"dark" | "light" | "system"default "dark"The color scheme before a reader chooses one.
systemfollows their operating system; the other two don't. See Theming.themeSelectorbooleandefault trueShows a swatch button in the corner of CloudCannon's Visual Editor that opens these theme settings. Visitors to the published site never see it.
theme.accentLightstringThe interactive color in light mode — links, the active sidebar item, focus rings and code annotations.
theme.accentDarkstringThe same role in dark mode. Use a paler step than the light one.
theme.brandLightstringPrimary button and brand fill in light mode.
theme.brandDarkstringPrimary button and brand fill in dark mode.
theme.radiusnumberCorner rounding in pixels, driving every radius on the site.
0is square.
seo.json
siteNamestringrequiredThe site's name in structured data, and the brand name when a page sets none.
urlstringrequiredThe production URL, used for canonical links and structured data. Keep it equal to
siteinastro.config.mjs—npm run checkwarns while either is stillhttps://example.com.descriptionstringThe meta description for any page without its own.
titleFormatstringThe browser title.
{title}is replaced with the page's title:{title} | Acmegives "Installation | Acme".logoSourcestringThe social share image for pages that set no
image. Empty means link previews show no picture.faviconSourcestringdefault "/favicon.svg"The browser tab icon, as an SVG.
faviconIcoSourcestringdefault "/favicon.ico"The fallback tab icon for browsers without SVG favicon support.
twitterSitestringThe site's X (Twitter) handle, including the
@. Optional.
footer.json
links{ name, path }[]Text links in the footer.
socials{ icon, link }[]Icon links.
iconis an id fromsrc/icons/, such associal/github.footerTextstringThe line of small print — a copyright notice or license.
announcementBar.json
enabledbooleanShows the bar at the top of every page.
textstringThe message, in Markdown, so it can carry a link. A reader who dismisses the bar doesn't see it again until the text changes.
breadcrumbs.json
homeLabelstringdefault "Docs"Label for the first crumb, which links to the site root.
redirects.json
routes{ from, to, status }[]Old URLs and where they go now.
fromis a path on this site;tois a path or a full URL;statusis"301"(permanent) or"302"(temporary). Add one whenever a page is renamed or moved, so shared links keep working.
Redirects only work on CloudCannon hosting
npm run build turns these into CloudCannon's routing file, so they take effect on the next build of a CloudCannon-hosted site. Another host ignores them — recreate them in that host's own redirect config.
Reading config in a component
Each file in src/data/ is a plain JSON import, so any component can read it directly — there is no config loader to learn.
---
import header from "@data/header.json";
---
<nav>
{header.topbarLinks.map((link) => <a href={link.path}>{link.name}</a>)}
</nav>import sidebar from "./src/data/sidebar.json" with { type: "json" };
console.log(sidebar.navGroups.map((group) => group.name));