Data mode uses createBrowserRouter and RouterProvider to enable data loading, actions, and pending UI without the framework's Vite plugin. This is ideal for existing React applications that want to add data loading and mutation capabilities.
Works with
AI-first code editor with Composer
Before installing skills in Cursor, ensure your development environment meets these requirements:
node --versionreact-router-data-modeExecute the skills CLI command in your project's root directory to begin installation:
Fetches react-router-data-mode from remix-run/agent-skills and configures it for Cursor.
The CLI shows a list of agents. Use arrow keys and space to select Cursor:
Confirm successful installation by checking the skill directory location:
Restart Cursor to activate react-router-data-mode. Access via /react-router-data-mode in your agent's command palette.
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Submit your Claude Code skill and start earning
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
Save 3-5 hours per week on routine tasks
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
Accelerate learning and skill development by 2x
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
Improve work quality by 30-40% with less effort
0
total installs
0
this week
108
GitHub stars
0
upvotes
Run in your terminal
0
installs
0
this week
108
stars
Data mode uses createBrowserRouter and RouterProvider to enable data loading, actions, and pending UI without the framework's Vite plugin. This is ideal for existing React applications that want to add data loading and mutation capabilities.
createBrowserRouter with route objectsloader property on routesaction property<Link>, <NavLink>, <Form>, redirect, and useNavigateuseNavigationuseFetcher for mutations without navigationLoad the relevant reference for detailed guidance on the specific API/concept:
| Reference | Use When |
|---|---|
references/routing.md |
Configuring routes, nested routes, layout |
references/route-object.md |
Understanding route object properties |
references/data-loading.md |
Loading data with loaders |
references/actions.md |
Handling forms, mutations, validation |
references/navigation.md |
Links, programmatic navigation, redirects |
references/pending-ui.md |
Loading states, optimistic UI |
references/ssr.md |
Server-side rendering with data mode |
These are the most important patterns to follow. Load the relevant reference for full details.
import { createBrowserRouter, RouterProvider } from "react-router";
const router = createBrowserRouter([
{
path: "/",
Component: Root,
children: [
{ index: true, Component: Home },
{ path: "about", Component: About },
],
},
]);
ReactDOM.createRoot(root).render(<RouterProvider router={router} />);
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
? 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.
Use fetcher.formData to show expected results immediately:
function FavoriteButton({ itemId, isFavorite }) {
const fetcher = useFetcher();
// Optimistic: use pending form data, fallback to server state
const optimistic = fetcher.formData
? fetcher.formData.get("favorite") === "true"
: isFavorite;
return (
<fetcher.Form method="post" action={`/items/${itemId}/favorite`}>
<input type="hidden" name="favorite" value={String(!optimistic)} />
<button>{optimistic ? "★" : "☆"}</button>
</fetcher.Form>
);
}
See references/pending-ui.md for complete patterns.
If anything related to React Router is not covered in these references, you can search the official documentation:
Prerequisites
Time Estimate
15-45 minutes depending on use case complexity
Steps
Common Pitfalls
✓ Do
✗ Don't
💡 Pro Tips
✓ Use when
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
✗ Avoid when
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
asyrafhussin/agent-skills
anthropics/claude-code
mblode/agent-skills
github/awesome-copilot
sickn33/antigravity-awesome-skills
leonxlnx/taste-skill
Keeps context tight: react-router-data-mode is the kind of skill you can hand to a new teammate without a long onboarding doc.
I recommend react-router-data-mode for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.
Keeps context tight: react-router-data-mode is the kind of skill you can hand to a new teammate without a long onboarding doc.
react-router-data-mode fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.
react-router-data-mode has been reliable in day-to-day use. Documentation quality is above average for community skills.
react-router-data-mode has been reliable in day-to-day use. Documentation quality is above average for community skills.
Solid pick for teams standardizing on skills: react-router-data-mode is focused, and the summary matches what you get after install.
Solid pick for teams standardizing on skills: react-router-data-mode is focused, and the summary matches what you get after install.
We added react-router-data-mode from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.
Solid pick for teams standardizing on skills: react-router-data-mode is focused, and the summary matches what you get after install.
showing 1-10 of 35