Skip to content

docs: Add APSC174 backend optimization guide#4

Draft
JackSwitzer wants to merge 1 commit intomainfrom
claude/update-apsc174-website-pRlxb
Draft

docs: Add APSC174 backend optimization guide#4
JackSwitzer wants to merge 1 commit intomainfrom
claude/update-apsc174-website-pRlxb

Conversation

@JackSwitzer
Copy link
Owner

Summary

Added comprehensive optimization guide for the APSC174 backend to address critical performance issues causing slow TTFB and LCP metrics. This document outlines identified bottlenecks and provides step-by-step implementation instructions to achieve 4-10x performance improvements.

Key Changes

  • Documented critical issues: Missing static generation, client-side-only MDX rendering, and runtime serialization causing 500-1500ms delays per page load
  • Identified high-priority fixes:
    • Add generateStaticParams() to enable static generation for all 58 pages
    • Enable server-side MDX rendering by removing ssr: false dynamic import
    • Self-host KaTeX CSS instead of CDN fetch
    • Expand Vercel deployment to multi-region (US East, US West, Europe)
  • Provided implementation details: Code snippets for each fix with file locations and line numbers
  • Included performance projections: Expected improvements from 800-1500ms TTFB to 50-200ms, and LCP from 2-4s to 0.5-1.5s
  • Added cleanup recommendations: Remove unnecessary API routes, simplify middleware matcher, and clean up redundant webpack config

Implementation Priority

  1. Static generation (highest impact)
  2. Server-side MDX rendering
  3. Self-hosted KaTeX CSS
  4. Multi-region deployment
  5. Middleware simplification
  6. Config cleanup

Notes

  • Build time will increase from ~30s to ~60s due to static generation, but runtime compute moves to build time
  • Aligns optimization patterns with existing JackSwitzer.com implementation
  • All changes are backward compatible and can be implemented incrementally

Comprehensive documentation for optimizing apsc174.jackswitzer.com:
- Current tech stack analysis
- Identified performance issues (no static generation, runtime MDX, etc.)
- Step-by-step fix implementation
- Expected 60-80% performance improvement
@vercel
Copy link

vercel bot commented Jan 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
jack-switzer Ready Ready Preview, Comment Jan 26, 2026 2:01pm

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants