Back to projects
2026Full Stack Developer

Bilingual Technical Portfolio with Astro SSG & Strict CSP

Bilingual (ES/EN) static portfolio built with Astro 7, strict TypeScript, and dark-only native CSS, featuring zero client JavaScript, script-src 'none' CSP, and 51 automated tests.

  • Astro
  • TypeScript
  • CSS nativo
  • Node.js
  • GitHub Actions
  • Lighthouse CI
Architecture diagram of the bilingual Astro 7 SSG technical portfolio with build-time guards, zero client JS, and strict CSP on Cloudflare Pages

Problem

Building a bilingual (Spanish/English) engineering portfolio that demonstrates verifiable standards in HTTP security, WCAG 2.2 AA accessibility, supply-chain hardening, and performance without shipping heavy client-side frameworks.

Architecture and decisions

  • Static by default with 0 KB client JS: built with Astro 7 SSG, strict TypeScript 6, and dark-only native CSS (color-scheme: dark), enabling a strict HTTP CSP with script-src 'none' and style-src 'self'.
  • Build-time integrity guards: typed collections and custom validators enforcing ES/EN translation parity, section order, ISO dates, safe URLs, and zero inline styles or scripts in dist/.

Challenges

  • Eliminating every inline style and script (no Shiki, no <ClientRouter />, native CSS @view-transition) to comply with script-src 'none' and style-src 'self'.
  • Tuning fallback font metrics for self-hosted Geist Sans and Geist Mono variable WOFF2 files to achieve CLS = 0 and 100/100 across all four Lighthouse CI categories.

Outcomes

Reproducible GitHub Actions pipeline with SHA-pinned actions, 7-day dependency quarantine, 51 automated tests via node:test, and 100 / 100 / 100 / 100 Lighthouse CI scores.