react-router-framework-mode
remix-run/agent-skills · Agent Skill
React Router modelli nel framework per loader, azioni, middleware, moduli di routing e flussi di rendering a schermo intero.
Vai all'installazione ↓Panoramica
| Autore | |
|---|---|
| Repository | remix-run/agent-skills ↗ |
| Cartella dello skill | react-router-framework-mode |
| Stelle | 134 |
| Fork | 4 |
| File inclusi | 13 |
| Licenza | MIT |
| Aggiornato | 18 giugno 2026 |
| Link | Sorgente dello skill ↗ · Repository ↗ |
Verifica Mozgi
Cosa abbiamo trovato nei file dello skill. I dettagli con l’abbonamento.
Installazione
Uno skill è una cartella con un file SKILL.md. Scegli il tuo agente ed esegui i comandi in un terminale (macOS, Linux o Git Bash su Windows) dalla radice del progetto.
Incolla il prompt in Claude, Codex o un altro assistente: controllerà lo skill e lo installerà.
Install the “react-router-framework-mode” skill from mozgi.io (https://mozgi.io/skills/remix-run-react-router-framework-mode/) for me. 1. Download the archive: https://mozgi.io/skills/remix-run-react-router-framework-mode/download If it fails, take the skill folder from the source: https://github.com/remix-run/agent-skills/tree/main/skills/react-router-framework-mode 2. Read SKILL.md and the other files. Check the skill is safe: no hidden commands, no sending data elsewhere, no scripts doing something other than described. If anything looks suspicious, stop and tell me. 3. Put the “react-router-framework-mode” folder into your agent's skills folder: .claude/skills/ for Claude Code, .agents/skills/ for Codex, .cursor/skills/ for Cursor, .gemini/skills/ for Gemini CLI. Inside the project if we are in one, otherwise in the home folder (~/.claude/skills/ etc.). 4. Make sure <skills folder>/react-router-framework-mode/SKILL.md exists. 5. Briefly tell me what this skill does and offer to try it on my task. If you cannot do a step yourself, tell me what to click or type.
git clone --depth 1 --branch main https://github.com/remix-run/agent-skills.git /tmp/agent-skills mkdir -p .claude/skills cp -r /tmp/agent-skills/skills/react-router-framework-mode .claude/skills/react-router-framework-mode
Riavvia Claude Code: lo skill compare nell'elenco; per richiamarlo a mano usa /react-router-framework-mode. Per tutti i progetti: ~/.claude/skills.
git clone --depth 1 --branch main https://github.com/remix-run/agent-skills.git /tmp/agent-skills mkdir -p .agents/skills cp -r /tmp/agent-skills/skills/react-router-framework-mode .agents/skills/react-router-framework-mode
Codex cerca gli skill in .agents/skills dalla cartella corrente fino alla radice del repo; richiamalo con /skills o $react-router-framework-mode. Per tutti i progetti: ~/.agents/skills.
git clone --depth 1 --branch main https://github.com/remix-run/agent-skills.git /tmp/agent-skills mkdir -p .cursor/skills cp -r /tmp/agent-skills/skills/react-router-framework-mode .cursor/skills/react-router-framework-mode
Cursor carica lo skill all'avvio; richiamalo con “/” nella chat Agent. Cursor legge anche .claude/skills e .agents/skills. Per tutti i progetti: ~/.cursor/skills.
git clone --depth 1 --branch main https://github.com/remix-run/agent-skills.git /tmp/agent-skills mkdir -p .gemini/skills cp -r /tmp/agent-skills/skills/react-router-framework-mode .gemini/skills/react-router-framework-mode
Gemini CLI propone di attivare lo skill quando il compito corrisponde: tu confermi. Per tutti i progetti: ~/.gemini/skills.
Leggi SKILL.md e i file correlati prima di installare. Clicca un file per l'anteprima.
Contenuto di SKILL.md
Testo originale dell'autore · sola letturaReact 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:
| Reference | Use When |
| ------------------------------------ | ----------------------------------------------------- |
| references/routing.md | Configuring routes, nested routes, dynamic segments |
| references/route-modules.md | Understanding all route module exports |
| references/special-files.md | Customizing root.tsx, adding global nav/footer, fonts |
| references/data-loading.md | Loading data with loaders, streaming, caching |
| references/actions.md | Handling forms, mutations, validation |
| references/navigation.md | Links, programmatic navigation, redirects |
| references/pending-ui.md | Loading states, optimistic UI |
| references/error-handling.md | Error boundaries, error reporting |
| references/rendering-strategies.md | SSR vs SPA vs pre-rendering configuration |
| references/middleware.md | Adding middleware (requires v7.9.0+) |
| references/sessions.md | Cookie sessions, authentication, protected routes |
| references/type-safety.md | Auto-generated route types, type imports, type safety |
Version Compatibility
Some features require specific React Router versions. Always verify before implementing:
npm list react-router
| Feature | Minimum Version | Notes |
| ----------------------- | --------------- | ----------------------------- |
| Middleware | 7.9.0+ | Requires v8_middleware flag |
| Core framework features | 7.0.0+ | loaders, actions, Form, etc. |
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:
// ✅ Correct
<Form method="get">
<input name="q" />
</Form>
// ❌ Wrong - don't manually handle search params
<form onSubmit={(e) => { e.preventDefault(); setSearchParams(...) }}>
Inline mutations - use useFetcher, NOT <Form> (which causes page navigation):
const fetcher = useFetcher();
const optimistic = fetcher.formData?.get("favorite") === "true" ?? isFavorite;
<fetcher.Form method="post" action={`/favorites/${id}`}>
<button>{optimistic ? "★" : "☆"}</button>
</fetcher.Form>;
See references/actions.md for complete patterns.
Layouts
Global UI belongs in root.tsx - don't create separate layout files for nav/footer:
// app/root.tsx - add navigation, footer, providers here
export default function App() {
return (
<div>
<nav>...</nav>
<Outlet />
<footer>...</footer>
</div>
);
}
Use nested routes for section-specific layouts. See references/routing.md.
Route Module Exports
meta uses loaderData, not deprecated data:
// ✅ Correct
export function meta({ loaderData }: Route.MetaArgs) { ... }
// ❌ Wrong - `data` is deprecated
export function meta({ data }: Route.MetaArgs) { ... }
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:
https://reactrouter.com/docs
Domande frequenti
Che cosa fa lo skill react-router-framework-mode?
React Router modelli nel framework per loader, azioni, middleware, moduli di routing e flussi di rendering a schermo intero.
Come si installa react-router-framework-mode?
Apri il blocco “Installazione” in questa pagina e scegli il tuo agente — Claude Code, Codex, Cursor o Gemini CLI — per i comandi pronti che copiano la cartella dello skill nel posto giusto. Oppure copia il prompt dalla scheda “Con l'assistente” e lascia che sia l'assistente a controllare e installare lo skill.
Con quali modelli AI funziona react-router-framework-mode?
Gli skill sono semplici istruzioni in Markdown (formato Agent Skills), quindi react-router-framework-mode funziona con qualsiasi agente che legge SKILL.md: Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode e altri. Il modello carica le istruzioni solo quando il compito corrisponde alla descrizione dello skill.
react-router-framework-mode è gratuito?
Lo skill è pubblicato apertamente da remix-run con licenza MIT. Lo skill in sé non costa nulla: paghi solo il tuo fornitore AI per i token usati.
È sicuro installare gli skill?
Uno skill è un insieme di istruzioni che il tuo agente seguirà: leggi SKILL.md e i file correlati prima di installarlo. Gli script nella cartella dello skill vengono eseguiti solo se li esegue l'agente: controlla cosa fa e non concedere permessi superflui.
In cosa differisce uno skill da un server MCP o da un plugin?
Un server MCP o un plugin danno al modello nuovi strumenti: codice che viene eseguito e restituisce un risultato. Uno skill fornisce conoscenza e metodo: come affrontare il compito, quali passi seguire e com'è un buon risultato. Non servono server né chiavi API.