Project 59 of 84
Next Blueprints
Private TypeScript micro-frontend monorepo template: a Next.js shell host that proxies independently built and deployed content zones at request time behind one origin, plus two bundled standalone full-stack SaaS starters.
- Status
- In progress
- Last activity
- 2026
- Live
No public deployment.
- Stack
- TypeScript
- Next.js / React
- Next.js and Next.js
- Turborepo
- pnpm workspaces
- nuqs
- Supabase auth
- Stripe Checkout
Highlights
- Found and fixed a client-side Stripe secret exposure in a bundled SaaS starter: replaced a 'use client' Stripe SDK client built from a NEXT_PUBLIC_ key (inlined into the browser bundle) with a server-only POST /api/checkout bound to the verified Supabase user and an allowlist of price ids, and removed a client-side has_paid self-grant (PR #5).
- Rebuilt server-side entitlement for Stripe Checkout: the success route re-fetches the session with line items and grants access only when app tag, payment mode and verified user all match, backed by 6 node:test cases and a Postgres trigger that blocks non-service-role writes to has_paid.
- Replaced five hand-copied Vercel deploy jobs with one data-driven GitHub Actions matrix that deploys only changed zones (all 26 on a shared-package change), resolves each zone's project secret by naming rule, and fails loudly on a missing secret before checkout (PR #6).
- Added the monorepo's first pull_request CI gate (turbo lint/typecheck/test/build with --affected against full history; 127/127 tasks green before merge) and stopped Vercel double deploys by disabling native git auto-deploy on five CI-deployed projects (PRs #1, #2).
- Wired a published-artifact secret scan (gitleaks + trufflehog, counts-only output, git-archive tree to avoid build-output false positives) ahead of every Vercel deploy job, consuming the shared scanner as a private GitHub Package instead of a cross-repo checkout.
- Migrated the repo into the catesworks org (transfer + rename), moved all CI to self-hosted macOS ARM64 runners on Node 24, and swapped per-repo lint config for the shared @cogs ESLint/Prettier packages across 27 zones.
- Generated evidence-based CODING_STANDARDS.md and GLOSSARY.md from the repo's real code and config, including measured inconsistency counts and flagged naming ambiguities (PR #4).
- Authored a generalized Render deployment runbook skill capturing three non-obvious production gotchas (silently skipped Free-plan predeploy commands, per-service pooler assumptions, env-apply vs rebuild) with a reusable per-service runbook template.