Documentation site for NextFTC v2, built with Astro and Starlight. Deployed to nextftc.dev.
.
├── public/
├── src/
│ ├── assets/
│ ├── content/
│ │ └── docs/
│ ├── styles/
│ │ └── custom.css
│ └── content.config.ts
├── astro.config.mjs
├── package.json
└── tsconfig.json
Starlight looks for .md or .mdx files in src/content/docs/.
Each file is exposed as a route based on its file name.
Images can be added to src/assets/ and embedded in Markdown with a relative link.
Static assets, like favicons, go in public/.
All commands are run from the root of the project, from a terminal:
| Command | Action |
|---|---|
bun install |
Installs dependencies |
bun dev |
Starts local dev server at localhost:4321 |
bun run build |
Build the production site to ./dist/ |
bun preview |
Preview the build locally, before deploying |
bun astro ... |
Run CLI commands like astro add, astro check |
bun astro -- --help |
Get help using the Astro CLI |
The site is hosted on Cloudflare Workers as a static assets Worker, configured in wrangler.jsonc.
- Production: pushes to
mainare built and deployed by Workers Builds, Cloudflare's git integration. This is configured in the Cloudflare dashboard, not in this repo. - Previews:
.github/workflows/build.yamlbuilds every PR withwithastro/action, which uploadsdist/as an artifact..github/workflows/preview.yamlthen picks that artifact up, runswrangler versions upload --preview-alias pr-<number>, and comments the preview URL on the PR. It needs theCLOUDFLARE_API_TOKENandCLOUDFLARE_ACCOUNT_IDrepository secrets.
Check out Starlight's docs, read the Astro documentation, or jump into the NextFTC Discord server.