For any frontend system design interview, structure your answer across these key areas. Depth depends on the role level and job description, but Core Architecture and Optimization are mandatory.
Focus on how the system is built and why.
- Choose based on application needs:
- CSR / SSR / SSG / ISR
- Streaming or partial rendering (if applicable)
- Discuss trade-offs: performance, SEO, scalability, cost
- Break UI into:
- Pages, layouts, modules
- Reusable and shared components
- Feature-based boundaries
- Clear separation of concerns (UI, logic, data)
- List required APIs
- Data contracts and response shapes
- Error handling and retry strategy
- Pagination, filtering, sorting
- Define state shape
- Normalize data where needed
- Derived vs source state
- Client cache vs server state
- Local vs global state
- Read-heavy vs write-heavy considerations
- Server state vs client state
- Tools (Context, Redux, Zustand, React Query, etc.)
Focus on performance, scalability, and reliability.
- Code splitting and lazy loading
- Tree shaking and dead code elimination
- Memoization and render optimization
- Adaptive loading (device/network aware)
- Preloading and prefetching
- Browser caching strategy
- Service workers
- PWA support
- Offline-first vs online-first
- Background sync
- Responsive design
- Touch interactions
- Network constraints
- Device-specific optimizations
- XSS, CSRF, CORS
- Secure headers
- Auth and token handling
- Input validation
- Locale handling
- Translation strategy
- Date, time, currency formats
- RTL support
- Semantic HTML
- Keyboard navigation
- ARIA roles
- Color contrast
- Screen reader support
- Metadata strategy
- Structured data
- Crawlability
- Performance impact on rankings
Focus on maintainability and team scalability.
- File and folder conventions
- Feature-based vs layer-based structure
- Shared vs domain-specific code
- Component patterns
- State patterns
- Data-fetching patterns
- Error-handling patterns
- Build tooling (Webpack, Vite, etc.)
- Environment configurations
- Bundle analysis
- Build and test pipelines
- Environment promotions
- Rollbacks and monitoring
- Linting (ESLint, Stylelint)
- Formatting (Prettier)
- Pre-commit hooks
- Static analysis
- Unit tests
- Integration tests
- E2E tests
- Test pyramid alignment
- Code review guidelines
- Ownership and approvals
- Automated checks
- Core Architecture and Optimization are non-negotiable.
- Other areas vary by role and product type.
- Real-world knowledge matters — learn from existing systems and proven architectures.
- Always explain trade-offs, not just choices.