1. Project Overview & Quickstart (fastify/LICENSE)
LICENSE
Open-source repository fastify/LICENSE
Repository Details
- Repository: fastify/LICENSE
- Primary Language: Code
Note: High-volume repository documentation is actively indexed and synchronized by YakaAI.
2. Official Technical Reference & Guides (fastify/website)
Fastify Website
A redesigned home for Fastify β a fast and low overhead
web framework for Node.js. Built with Astro, Tailwind CSS v4, MDX
content collections, and Pagefind for static full-text search.
The design language is a dark-first "telemetry" aesthetic built around the one
thing Fastify is known for: speed. The signature element is a live
requests-per-second velocity gauge in the hero.
Stack
- Astro β static site generator
- Tailwind CSS v4 via
@tailwindcss/vite - MDX + Astro Content Collections for docs
- Pagefind β static, client-side search index
- Variable fonts: Space Grotesk (display), Inter (body), JetBrains Mono (code)
Commands
| Command | Action |
|---|---|
npm install |
Install dependencies |
npm run dev |
Start the dev server at localhost:4321 |
npm run build:website |
Build to build/, optimize production images, and generate the Pagefind search index |
npm run preview |
Preview the production build locally |
npm run lint |
Lint with Biome |
npm run format |
Format with Biome (format to verify) |
npm run check |
Type-check via astro check (run by CI on every PR) |
Search only works against a production build (
npm run build:website), because the
Pagefind index is generated from the built HTML. Indevthe search modal
shows a graceful fallback message.Production builds optimize imported SVG components with Astro and all supported
bundled and public image assets with Vite. Source image files are not modified.Icons come from Lucide (
@lucide/astro). The GitHub
star count is fetched client-side on page load so it always matches GitHub.
Internal links respect Astro'sbasevia thewithBasehelper in
src/lib/href.ts.
Project structure
src/
components/ UI: Nav, Footer, Search, VelocityMeter, CodeTabs, BenchBarsβ¦
content/
docs/ Documentation pages (md/mdx) β grouped by `section`
data/site.ts Central data: nav, features, sponsors, team, benchmarks, plugins
layouts/ BaseLayout (chrome, theme, fonts)
pages/ Routes: /, /ecosystem, /benchmarks, /organizations, /docs
styles/ global.css β design tokens + prose stylingFeature parity with the current site
This redesign preserves every user-facing capability of the current
Docusaurus site:
- Marketing homepage (hero, why, core features, quick start, benchmarks,
ecosystem, team, CTA) with copy-to-clipboard code samples. - Ecosystem page with client-side search + category filtering.
- Benchmarks page with animated comparison bars.
- Organizations & team page (production users, sponsors, maintainers).
- Docs with a sectioned sidebar, prev/next navigation, breadcrumbs, and
full-text search. - Dark/light theme toggle (no flash of unstyled theme), responsive nav with a
mobile menu, keyboard-accessible focus states, reduced-motion support.
Documentation pipeline
The documentation is not stored in this repository β it lives in thefastify/fastify repo and is fetched at
build time by scripts/fetch-docs.mjs, which runs
as part of npm run build:website.
The script:
- Lists all release tags with
git ls-remote(no auth, no rate limit). - Selects releases exactly like the official
fastify/websitebuild:- the current (highest) major β the latest patch of every minor
(e.g. all5.x); - each older major down to
DOCS_MIN_MAJOR(default3) β only its
latest release (e.g. the last4.xand the last3.x).
- the current (highest) major β the latest patch of every minor
- Downloads each release tarball and extracts only its
docs/folder. - Transforms every Markdown file β strips the repeated centered title,
rewrites relative.mdlinks and resource paths to site URLs, and injectstitle/section/order/versionfrontmatter. - Emits versioned content into
src/content/docs/<version>/β¦, copies image
resources intopublic/docs/<version>/β¦, duplicates the newest release aslatest, and writessrc/data/versions.json.
The result is browsable, versioned docs (latest, v5.10.x β¦ v5.0.x,v4.29.x, v3.29.x) with a version switcher, exactly like the current website.
Fetched content is git-ignored so the source of truth stays in fastify/fastify.
Version-scoped search: the Pagefind index tags every doc page with its
version. When you search from a docs page, results are filtered to the selected
version only (searching from a v5.10.x page returns v5.10.x results, neverv5.9.x or v4.x); elsewhere search defaults to latest.
Deployment
A GitHub Actions workflow (.github/workflows/deploy-website.yml)
builds and publishes the site to GitHub Pages on every push to main (and
on manual dispatch). It installs dependencies with npm, fetches the docs, runsastro build + Pagefind, and deploys the build/ output.
To enable it: in the repository settings, set Settings β Pages β Build and
deployment β Source to GitHub Actions.
The site is configured for a root deployment (as used by
fastify.devvia
a custom domain). If you deploy to a project subpath
(https://.github.io/<repo>/), set Astro'sbase
and add a matching custom domain /CNAMEaccordingly.