The public Construct Computer website. It preserves the established landing-page design while replacing the previous custom build and router with a statically prerendered React application.
- React Router framework mode with Vite and React 19
- Tailwind CSS 4 and shadcn/Radix primitives
- Repository-authored MDX editorial content
- Cloudflare Pages, Pages Functions, D1, Turnstile, and WAF
- PostHog analytics and masked session replay
- Vitest, Playwright, axe, ESLint, Prettier, and strict TypeScript
| Command | Purpose |
|---|---|
pnpm dev |
Start the UI development server |
pnpm build |
Generate discovery files and prerender every public route |
pnpm preview |
Serve the built site and Pages Functions with Wrangler |
pnpm test |
Run unit and API tests |
pnpm test:e2e |
Build and test the deployed Pages behavior in Chromium |
pnpm lint |
Run ESLint |
pnpm typecheck |
Generate route types and run TypeScript |
pnpm check |
Run lint, types, unit tests, and the production build |
- Install Node 24 and pnpm 11.15.0.
- Run
pnpm install. - Use
.env.examplefor public Vite variables and.dev.vars.examplefor local Pages secrets. - Apply the local database migration with
pnpm wrangler d1 migrations apply DB --local. - Run
pnpm devfor UI work orpnpm test:e2efor the complete Pages, Function, Turnstile, and D1 flow.
Cloudflare's published Turnstile test keys are intentionally included in the example and E2E configuration. Production keys must be configured in Cloudflare.
app/features/landing/owns the homepage sections, motion, media, and beta modal.app/content/is the editorial source of truth.app/content/resources.tsmaps generated MDX metadata into one ordered collection.- Every editorial resource uses
/blog/<slug>/; company and legal utilities remain top-level. app/lib/route-manifest.tsdrives prerendering, canonical metadata, sitemap entries, feeds, crawler files, and OG images.functions/api/beta-signup.tsis the only application endpoint.scripts/finalize-build.mjscreates a real404.htmland removes the SPA fallback.
See docs/decisions/001-static-prerendered-react.md for the architectural rationale and docs/search-and-deployment.md for production setup and indexing operations.
Add articles, guides, and comparisons as MDX under app/content/blog/. The filename is the canonical /blog/<slug>/ slug, and every file is discovered automatically.
Frontmatter requires title, description, published (YYYY-MM-DD), a registered author ID, nonempty tags, kind (article, guide, or comparison), and draft. seoTitle is optional. Add updated only after a substantive update and use a date later than published. Run pnpm generate:content; the build fails on invalid or stale metadata.
The homepage social image source is assets/og/home.png. Generation copies it to public/og/home.png after rebuilding other OG images, so replace the source file rather than editing the generated copy.
pnpm check && pnpm test:e2e is the release gate. It verifies all canonical pages, legacy redirects, the real 404 response, the ordered resource grid, Turnstile plus D1 signup, and automated accessibility checks.