Mục tiêu: Hiểu rõ bản chất, trade-offs, và chọn đúng stack cho từng loại dự án.
1. Bản Chất: Library vs Framework vs Build Tool
React (Library)
├── Chỉ lo UI rendering (components, state, lifecycle)
├── KHÔNG có routing, data fetching, build tool
├── Bạn TỰ chọn: router, state management, bundler, CSS solution
└── Flexible nhất, nhưng phải setup nhiều
Next.js (Full-stack Framework)
├── Built ON TOP of React
├── CÓ SẴN: routing, SSR/SSG, API routes, caching, optimization
├── Opinionated: file-based routing, `app/` directory