- Create src/lib/api.ts with fetchLeaderboard function for server use
- Update page.tsx to async component that fetches data at build/request time
- Pass fetched data to ClientPage as initialAppData prop
- Remove client-side useEffect and state management from ClientPage
- Reduce client bundle size (4.07kb → 2.99kb)
- Improve security by keeping API credentials server-only
- Create ClientPage.tsx with 'use client' and all stateful logic
- Simplify page.tsx to just import and render ClientPage
- Allows easy switching between client/server rendering strategies
- Maintains same functionality with cleaner separation of concerns
- Create Next.js app with TypeScript, Tailwind, and Postcss
- Extract API logic, types, and utilities to lib/
- Build React components for Race Results, Driver Standings, Points Key, and D3 Chart
- Use environment variables for API credentials (NEXT_PUBLIC_*)
- Static export (output: 'export') for Cloudflare Pages deployment
- D3 chart rendered client-side with dynamic import
- Update deploy workflow to build and deploy ./out directory
- Remove original public/index.html