Set Up Compass
Install Compass, run it locally, and make the first project-level updates.
Compass is a docs template, so the first setup step is really about making the repository yours: create a new repo from the template, get it running, update the site identity, and replace the sample information architecture.
Create your docs repository
Start from the GitHub template instead of installing Compass as an npm dependency:
- Open the Compass repository on GitHub
- Click Use this template
- Create a new repository for your product docs, support center, or internal knowledge base
- Clone your new repository locally
Install and run locally
From your new project root:
npm install
npm run dev
That starts Astro’s local server so you can preview the homepage, category pages, and article templates while you edit.
Update the project identity
These are the first files most teams touch:
site.config.mjsfor title, URLs, and repository linkspackage.jsonfor the local project name and metadatasrc/data/docs.tsfor parent categories and sub-categoriessrc/content/docsfor article contentREADME.mdfor package and contributor guidance
Confirm the core scripts
Compass ships with a small set of scripts you can use during development:
npm run dev
npm run check
npm run build
npm run preview
devruns the local Astro servercheckvalidates Astro, TypeScript, and content usagebuildgenerates the production sitepreviewserves the production build locally
Recommended first edits
Once the project is running, make these changes before publishing:
- Replace the placeholder
siteUrlinsite.config.mjs - Rename the sample categories in
src/data/docs.ts - Rewrite the sample content in
src/content/docs - Confirm the navigation labels in the header match your docs structure
What to expect next
After that, the next step is learning how Compass organizes categories, articles, and routes so you can reshape it without guesswork.