Performance

Dashboard loads 3x faster

We optimized the dashboard loading time from ~1.5s to under 500ms — a 3x improvement.

What we did

Database optimization

Added proper indexes for the most common query patterns:

CREATE INDEX idx_posts_project_status 
  ON posts(project_id, status, published_at DESC);

CREATE INDEX idx_subscribers_project_status
  ON subscribers(project_id, status);

Server components

Converted data-fetching pages to React Server Components, eliminating unnecessary client-side JavaScript. The post list page went from 48KB to 12KB of client JS.

Edge caching

Static assets are now cached at the edge via Vercel's CDN with proper cache headers.

Lazy loading

Below-the-fold content (subscriber table, older posts) is lazy-loaded on scroll.


Average dashboard load time: 480ms (down from 1,520ms). Measured with Lighthouse on a simulated 4G connection.