Objective
Publish projects in two languages by writing content files, not code.
English/Spanish site where each project is a pair of Markdown files. Includes search, category and tag filters, an image gallery with lightbox, light/dark theme, per-locale SEO metadata, and API routes for a streaming Claude assistant.
Challenges
- 01Adding a project should require content files only, no code changes
- 02Two languages without duplicating layout or components
- 03A public LLM endpoint receiving untrusted conversation history
How it was solved
- 01Markdown files with Zod-validated frontmatter, read and rendered at build time
- 02next-intl locale routing over a single component tree
- 03Server-owned system prompt and tools, whitelisted roles, per-IP rate limit
Results
- Adding a project takes one Markdown file per language
- Every page is statically generated
Overview
This site. It presents Fer’s projects in English and Spanish and includes a chat assistant that answers questions about them and can forward a visitor’s contact details.
Technical Implementation
Content
Projects live in content/projects/ as <slug>.mdx and <slug>.es.mdx. Gray Matter extracts the frontmatter, Zod validates it, and markdown-it renders the body; the slug comes from the file name. A CI script checks images, EN/ES parity and tag rules.
Internationalization
next-intl serves /en and /es from one component tree. Sitemap, canonical URLs, hreflang, Open Graph images and JSON-LD are generated per locale.
Assistant
A Node.js route streams Claude responses. The system prompt, cached as a stable prefix, holds every project plus the profile. A contact tool sends visitor details through Resend; if a service is missing, the assistant degrades to the next fallback.
Features
- Search with category and tag filters in the active language
- Gallery with lightbox, grouped into web and mobile screenshots
- Light/dark theme following the system preference
- Scroll-driven animations in plain CSS, switched off under reduced motion
Technologies
- Next.js 16
- React 19
- TypeScript
- Tailwind CSS 4
- next-intl
- markdown-it
- Gray Matter
- Zod
- Radix UI
- next-themes
- Claude API
- Resend
- Upstash Redis
- Vercel
