react-router-v7-app

react-router-v7-app is a skill for Claude Code from atman-33/workhub. It costs 46 tokens per session (1,463 once invoked), scanned A, original, MIT.

A set of implementation patterns for applications built with React Router version 7, a JavaScript library for connecting web pages to URL paths. It covers route files, server data loading, form actions, and loading states.

In plain words
What is it for?
Use it when creating or changing React Router 7 routes, loaders, actions, components, and related tests.
Why use it?
It gives a React Router project a consistent structure and reduces uncertainty about where routes, data fetching, and form logic belong.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the stack-react-router plugin — 1 skill shipped together

Good fit Use it when creating or changing React Router 7 routes, loaders, actions, components, and related tests.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/atman-33/workhub/react-router-v7-app
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add atman-33/workhub --skill react-router-v7-app
Clone the repo
git clone --depth 1 https://github.com/atman-33/workhub

Made for: Claude Code.

Or install stack-react-router, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for react-router-v7-app

README.md
[![agentmods](https://agentmods.dev/badge/skills/atman-33/workhub/react-router-v7-app/github.svg)](https://agentmods.dev/skills/atman-33/workhub/react-router-v7-app)
Your own site
<a href="https://agentmods.dev/skills/atman-33/workhub/react-router-v7-app"><img src="https://agentmods.dev/badge/skills/atman-33/workhub/react-router-v7-app/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for react-router-v7-app

Your own site · 80×15
<a href="https://agentmods.dev/skills/atman-33/workhub/react-router-v7-app"><img src="https://agentmods.dev/badge/skills/atman-33/workhub/react-router-v7-app.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,463 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00046 $0.01463
Opus 5.5 $0.00018 $0.00585
Sonnet 5.5 $0.00009 $0.00293
Haiku 4.5 $0.00005 $0.00146

Measured 1mo ago against content hash 3079de32f6d2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

react-router-v7-app scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/stack-react-router/skills/react-router-v7-app/SKILL.md · 206 lines

How it starts

The opening of the file, as written. The whole thing — 206 lines — stays where its author put it; the contents beside it link to each section on GitHub.

React Router v7 App Implementation

1. Route Structure

  • Use file-based routing in app/routes/.
  • Route files: route.tsx for route components.
  • Prefer folder routes like users.$id/route.tsx when a route needs colocated helpers, components, or tests; sibling files in the folder do not become routes.
  • If tests live under app/routes/, configure flatRoutes({ ignoredRouteFiles: [...] }) to exclude *.test.* and *.spec.* from route discovery.
  • Use underscore prefix for route groups: _app, _landing.
  • Use dot notation for nested routes: users.$id.tsx.

2. Data Loading Patterns

  • Use loader functions for server-side data fetching.
  • Use action functions for form submissions and mutations.
  • Leverage useLoaderData() and useActionData() hooks.
  • Handle loading states with useNavigation().

3. Route Component Structure

Use arrow functions for all exports.

import type { Route } from './+types/route';

export const loader = async ({ request, params, context }: Route.LoaderArgs) => {
  // Server-side data loading
  // Return an object
  return { ... };
};

export const action = async ({ request, params, context }: Route.ActionArgs) => {
  // Handle form submissions and mutations
  // Return an object
  return { ... };
};

const Page = ({ loaderData, actionData }: Route.ComponentProps) => {
  // Component implementation with typed props
  return (
    <div>
      {/* Content */}
    </div>
  );
};

export default Page;

4. Error Handling

  • Use ErrorBoundary components for route-level error handling.
  • Implement proper error responses in loaders/actions.
  • Use isRouteErrorResponse() for typed error handling.

5. Meta and Headers

  • Export meta function for dynamic page metadata.
  • Export headers function for custom HTTP headers.
  • Use proper SEO practices with meta tags.

6. Project Structure

The app folder should follow this structure:

public                # Static files (images, fonts, etc.)
|
app
|
+-- components        # Shared components
|
+-- config            # Global configuration and environment variables
|
+-- constants         # Global constants
|
+-- hooks             # Shared hooks
|
+-- lib               # Pre-configured reusable libraries
|
+-- routes            # React Router routing directory
|
+-- stores            # Global state stores
|
+-- testing           # Test utilities and mock servers
|
+-- types             # Base types used across the application
|
+-- utils             # Shared utility functions
|

Read the full file on GitHub · 206 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 206 lines · 46 tokens per session scan A 3079de32f6d2

Subscribe to this mod's changes

react-router-v7-app is a skill published in the GitHub repository atman-33/workhub (3 stars, last pushed 2d ago), licensed MIT. It adds 46 tokens to every session and 1,463 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

migrate-radix-to-base

Migrates React projects and components from Radix UI to Base UI. Use when asked to migrate from radix, move to base-ui, convert radix primitives, or switch a shadcn project's base library. Handles single components ("migrate accordion") and whole projects.

Mikedev115/Aetox · 61 tokens

add-localization

Adds or extends multilingual localization in a Power Pages code-site SPA. Use whenever the user asks to translate, localize, internationalize, support multiple languages, add a language selector, add locale routes, repair an i18n setup, or add languages to an existing React, Vue, Angular, or Astro Power Pages site.

microsoft/power-platform-skills · 69 tokens

gonavi-cli

Operate databases through the GoNavi headless CLI — the gonavi executable shipped in verified GitHub Release archives. Covers listing/adding/importing saved connections, running SQL queries against saved connections or ad-hoc connection files, exporting result sets to csv/json/md/html/xlsx, batch-executing SQL files…

Syngnat/GoNavi · 144 tokens

pcf

Builds, tests, diagnoses, upgrades, deploys and verifies Power Apps component framework (PCF) code components for model-driven apps and Power Pages — field and dataset controls, standard and virtual (React) — from Microsoft-maintained templates and recipes pinned to a tested version matrix. Runs quality gates…

microsoft/power-platform-skills · 171 tokens

recipe-front-review

Reviews completed frontend implementation for governing-source compliance, scope economy, repository quality, and security, then applies user-approved React corrections.

shinpr/claude-code-workflows · 29 tokens

typescript-rules

React/TypeScript frontend development rules including type safety, component design, state management, and error handling. Use when implementing React components, TypeScript code, or frontend features.

shinpr/claude-code-workflows · 39 tokens