Getting started
mom-doc-theme is a complete Astro + Starlight project. You do not copy it. A content repo references it by git coordinate, and remote-astro-theme fetches it and builds your content with it.
What your repo contains
Section titled “What your repo contains”my-docs-repo/├── package.json # devDependency on remote-astro-theme + scripts└── docs/ ├── site.config.mjs # steering config (theme, title, sidebar, ...) ├── content/ # your .md / .mdx pages └── assets/ # optional images, referenced from contentThere is no Astro config, no src/ and no Starlight setup in your repo.
Set up
Section titled “Set up”-
Add the CLI and scripts to
package.json:{"scripts": {"dev": "remote-astro-theme dev","build": "remote-astro-theme build","preview": "remote-astro-theme preview"},"devDependencies": {"@mindovermachine-dev/remote-astro-theme": "^0.1.0"}} -
Create
docs/site.config.mjs:export default {theme: "mindovermachine-dev/mom-doc-theme@main",title: "My docs",defaultLocale: "root",locales: { root: { label: "English", lang: "en" } },rootRedirect: null,sidebar: [{ label: "Guide", items: [{ autogenerate: { directory: "guide" } }] },],}; -
Add pages under
docs/content/. Each page needstitleanddescriptionfrontmatter. -
Run
npm install, thennpm run dev. The site is built todist/bynpm run build.
Pin the theme
Section titled “Pin the theme”@main is re-fetched on every run. For CI and production, pin a tag or a full commit SHA: mindovermachine-dev/mom-doc-theme@v1.0.0. Only full 40-character SHAs are cached.
Hosting under a sub-path
Section titled “Hosting under a sub-path”For GitHub Pages project sites, set astro.base and astro.site (see Steering config). Root-absolute links in content, such as hero action links, do not get the base added. Include it yourself, for example /my-repo/guide/intro/.