Launch Route Performance Budgets
Last updated: 2026-06-02
Purpose
task-0596 adds a repo-native route performance report for launch-critical surfaces: dashboard, cases, case detail, documents, calendar, communications, billing, and portal dashboard.
Command
npm run launch:route-performance
The command writes:
planning/launch-route-performance.jsonplanning/LAUNCH_ROUTE_PERFORMANCE.md
What It Measures
- Source-level route budget signals: source bytes, gzip bytes, static imports, dynamic imports, heavy package imports, and client/server boundary.
- Built-output budget signals when
.next/server/app-paths-manifest.jsonexists: route server bundle gzip, client reference manifest, client chunk count, and client chunk gzip. - Optional HTTP response benchmarks when a base URL is provided.
Benchmark Mode
npm run launch:route-performance -- --base-url http://localhost:3000 --iterations 5
Protected routes may measure redirects or unauthenticated responses unless the server has a seeded auth/session strategy. Use this as a route timing signal, not a substitute for authenticated Playwright workflow proof.
Operating Rules
- Keep the route list focused on launch-critical surfaces until bundle budgets are stable.
- Run after
npm run buildwhen built chunk sizes are needed. - Treat client entrypoints and heavy imports as follow-up candidates for server component conversion, focused client islands, or lazy-loaded panels.