Series: Spec-Driven Development with Claude Code — Part 1 · Part 2 · Part 3 In Part 1 we created the spec and scaffold. In Part 2 we implemented auth and data access. Today we close the loop: UI, route protection, deployment, and — most importantly — how to keep the spec alive as your product evolves. Because a spec that doesn't get updated is worse than no spec: it gives you false confidence. Step 1: Auth Middleware Protecting routes sounds simple but gets messy without a clear spec. Ours (US-5) says exactly what to protect: /products requires authentication /login and /register redirect to /products if already authenticated We ask Claude Code: > Read @specs/catalogo-guayoyo.md US-5. Implement the auth middleware in middleware/auth.ts. Use defineNuxtRouteMiddleware. No duplicated logic — the middleware should be generic.…