React Router
The standard React router. Declarative routing, nested routes, layouts, loaders/actions. Coeurdar uses v7 with React Router DOM for SPA routing.
Strengths
- Declarative nested routes, layouts that compose naturally with sub-routes
- Data API (loaders/actions) for data fetching colocated with routes
- Type-safe route generation with typegen (v7), no more magic strings
- ~15% smaller than v6, optimized bundle, non-breaking upgrade from v6
Limitations
- Migration v6→v7 is trivial but future flags need attention
- API shifted significantly between v5, v6, and v7, online examples are often outdated
- Loaders/actions push toward a framework pattern (Remix) not always suited for pure SPAs
Best for
- Any React SPA, routing, deep linking, browser navigation
- Apps with nested layouts and hierarchical navigation (Academy → Course → Module)