react-router-framework-mode
React Router framework-mode patterns for loaders, actions, middleware, route modules, and full-stack rendering flows.
Install
npx skills add https://github.com/remix-run/agent-skills --skill react-router-framework-mode- license
- MIT
React Router Framework Mode
Framework mode is React Router's full-stack development experience with file-based routing, server-side, client-side, and static rendering strategies, data loading and mutations, and type-safe route module API.
When to Apply
- Configuring new routes (
app/routes.ts) - Loading data with
loaderorclientLoader - Handling mutations with
actionorclientAction - Navigating with
<Link>,<NavLink>,<Form>,redirect, anduseNavigate - Implementing pending/loading UI states
- Configuring SSR, SPA mode, or pre-rendering (
react-router.config.ts) - Implementing authentication
References
Load the relevant reference for detailed guidance on the specific API/concept:
Version Compatibility
Some features require specific React Router versions. Always verify before implementing:
Critical Patterns
These are the most important patterns to follow. Load the relevant reference for full details.
Forms & Mutations
Search forms - use <Form method="get">, NOT onSubmit with setSearchParams:
Inline mutations - use useFetcher, NOT <Form> (which causes page navigation):
See references/actions.md for complete patterns.
Layouts
Global UI belongs in root.tsx - don't create separate layout files for nav/footer:
Use nested routes for section-specific layouts. See references/routing.md.
Route Module Exports
meta uses loaderData, not deprecated data:
See references/route-modules.md for all exports.
Further Documentation
If anything related to React Router is not covered in these references, you can search the official documentation: