Premium personal landing page built with Next.js 15 + Payload CMS 3.x, featuring bilingual support (PT + EN), a technical blog, case studies, and a command palette.
| Area | Technology |
|---|---|
| Framework | Next.js 15 (App Router) |
| CMS | Payload CMS 3.x (embedded) |
| Database | PostgreSQL 16 |
| Styling | Tailwind CSS 4.x |
| Animations | Framer Motion 11.x |
| i18n | next-intl 3.x |
| Resend | |
| Analytics | Umami (self-hosted) |
| Testing | Vitest + Playwright |
| Deploy | Railway |
- Node.js ≥ 20
- pnpm ≥ 9
- Docker + Docker Compose (for local PostgreSQL)
git clone <repo-url>
cd fabio-landing
pnpm installcp .env.example .env.local
# Edit .env.local with your valuesdocker-compose up db -dpnpm migrate
pnpm generate:types
pnpm generate:importmappnpm devSite: http://localhost:3000/pt Admin: http://localhost:3000/admin
| Command | Description |
|---|---|
pnpm dev |
Start development server |
pnpm build |
Production build |
pnpm start |
Start production server |
pnpm lint |
Run ESLint |
pnpm format |
Format with Prettier |
pnpm type-check |
TypeScript type check |
pnpm test |
Run unit tests |
pnpm test:coverage |
Unit tests with coverage |
pnpm test:e2e |
Run Playwright E2E tests |
pnpm migrate |
Run Payload DB migrations |
pnpm generate:types |
Generate Payload TypeScript types |
pnpm generate:importmap |
Regenerate Payload admin import map |
| Variable | Required | Description |
|---|---|---|
DATABASE_URI |
✅ | PostgreSQL connection string |
PAYLOAD_SECRET |
✅ | Payload CMS encryption secret (min 32 chars) |
NEXT_PUBLIC_SITE_URL |
✅ | Public base URL of the site |
RESEND_API_KEY |
✅ | Resend API key for transactional email |
RESEND_FROM_EMAIL |
✅ | Sender email address |
NOTIFICATION_EMAIL |
✅ | Email to receive contact form notifications |
NEXT_PUBLIC_UMAMI_WEBSITE_ID |
❌ | Umami analytics website ID |
NEXT_PUBLIC_UMAMI_URL |
❌ | Umami instance URL |
Set these in Railway via the environment variable UI. For local dev, use .env.local.
See .env.example for a template with all variables and example values.
src/
├── app/
│ ├── (frontend)/[locale]/ # Public site (PT + EN)
│ ├── (payload)/admin/ # Payload CMS admin panel
│ └── api/ # REST endpoints + health check
├── collections/ # Payload CMS collection configs
├── globals/ # Payload global configs
├── blocks/ # Payload content blocks
├── components/ # React components
├── i18n/ # Internationalization config + messages
└── lib/ # Shared utilities
- Create a Railway project with PostgreSQL service
- Connect your GitHub repository to a web service
- Set environment variables in Railway dashboard
- Auto-deploy triggers on push to
main
Health check: GET /api/health
Build command: pnpm build
Start command: node .next/standalone/server.js
Push to main triggers a production deploy. For staging, create a separate Railway environment connected to a staging branch.
Access the Payload admin panel at /admin. Create your first admin user on first visit.
Collections:
- Pages — Homepage content blocks
- Case Studies — Project case studies with metrics
- Posts — Blog posts with categories and tags
- Categories / Tags — Blog taxonomy
- Contact Submissions — Form submissions (read-only)
- Media — Image library with auto-generated sizes
Globals:
- Site Settings — Site-wide configuration (title, social links, navigation)
pnpm test # Run all unit tests
pnpm test:coverage # Run with v8 coverage report (threshold: 80%)Coverage scope: src/lib/**, src/utils/**, src/hooks/**
Requires a running application (or pnpm build && pnpm start).
pnpm test:e2e # Run all Playwright tests (headless)
pnpm test:e2e:ui # Run with Playwright UI modeE2E tests cover:
- Homepage load in PT and EN locales
- Locale switching (PT ↔ EN)
- Navigation (blog, case studies, contact)
- Contact form rendering and validation
- Command palette (keyboard shortcut ⌘K / Ctrl+K)
- 404 not-found page
- Accessibility (heading hierarchy, alt texts, focus management)
- Security headers (CSP, X-Frame-Options, HSTS, etc.)
- RSS feed (
/feed.xml) and sitemap (/sitemap.xml)
Set PLAYWRIGHT_BASE_URL to run against a non-localhost server.