CSR Performance Characteristics
What you'll learn: How to analyze the key performance metrics that reveal CSR's strengths and weaknesses in real-world applications.
Understanding CSR Performance Metrics
When your app uses Client-Side Rendering, the browser downloads a minimal HTML shell, fetches JavaScript bundles, executes them, and then renders content. This process affects three critical performance characteristics:
Time to Interactive (TTI)
TTI measures when users can actually interact with your page. In CSR apps, this typically happens late because:
- The browser must download all JavaScript first
- JavaScript must parse and execute
- The framework must build the initial view
- API requests may block interactivity
Think of it like a restaurant: customers can't order until the kitchen is fully set up and the menu is printed. CSR sets everything up client-side, which delays service.
First Contentful Paint (FCP)
FCP marks when users see anything meaningful on screen. CSR often has poor FCP because:
- The initial HTML is nearly empty (
<div id="root"></div>) - Content only appears after JavaScript executes
- Users stare at blank screens or loading spinners
This creates a perception of slowness even when the app eventually loads quickly.
Bundle Size Impact
Large JavaScript bundles directly harm both metrics:
- More bytes to download = longer wait before execution
- More code to parse = slower TTI
- Network conditions amplify these effects
A 500KB bundle on 3G might take 10+ seconds to download. Users see nothing during this time.
Key Takeaway: CSR apps typically have delayed FCP and TTI due to JavaScript-first architecture and bundle size overhead—understanding these trade-offs helps you optimize strategically and decide when CSR is appropriate.