tanstack-router
Skill1 starsChanged 3 months agoMITView on GitHub
Build, review, debug, configure, migrate, or plan TanStack Router React applications with current docs. Use for @tanstack/react-router, file-based routes, code-based routes, route trees, generated routeTree.gen files, routeFileIgnorePrefix colocation (-components/-hooks/-lib), pathless layouts, typed navigation, Link/useNavigate/redirect, params, validateSearch, loaderDeps, loaders, beforeLoad, route context, auth guards, notFound, error boundaries, pending/deferred data, preloading, TanStack Query integration, SSR, testing, and production routing rewrites.
16 other projects use a version of this.
Adopted by
Most recently taken up by
- marcioaltoe/skillstheir own version, first seen Nov 29, 2026
- dvaJi/argostheir own version, first seen Nov 23, 2026
- itsLeonB/agent-config-managertheir own version, first seen Nov 11, 2026
- yuan-alex/cedartheir own version, first seen Nov 8, 2026
- louisbrulenaudet/monorepo-templatetheir own version, first seen Oct 29, 2026
- Firzus/agent-skillstheir own version, first seen Oct 23, 2026
Used with
Projects with it also use accessibility, review and 1 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
MicrosoftSkillaccessibility
Consolidated accessibility skill entrypoint for WCAG 2.2, ARIA Authoring Practices, cognitive accessibility, Section 508, EN 301 549, design intent verification, and the Accessibility Planner workflow.
Also in 3 projects that use this
SentrySkillreview
Fixture review skill.
Also in 4 projects that use this
GoogleSkillimprove-codebase-architecture
Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
Also in 3 projects that use this
Other versions16 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 16
- Mindrally/skills★ 275same name
- TangleML/tangle-ui★ 104same name
- louisbrulenaudet/monorepo-template★ 19same name
- Firzus/agent-skills★ 6same name
- dvaJi/argos★ 4same name
- malinskibeniamin/skills★ 4same name
- Spardutti/claude-skills★ 3same name
- Aver005/agent-skills★ 2same name
- bm629/agent-skills★ 2same name
- lobomfz/skills★ 2same name
6 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository81 other files it gives its agents.
- AGENTS.mdAGENTS.md
- agents-mdSkill
- base-uiSkill
- better-authSkill
- brainstormSkill
- bullmqSkill
- bunSkill
- clickhouseSkill
- clone-to-tempSkill
- compound-uiSkill
- copywritingSkill
- create-durable-planSkill
- d3Skill
- date-fnsSkill
- decimal-jsSkill
- deduplicateSkill
- design-engineerSkill
- designSkill
- drizzle-ormSkill
- effectSkill
- elysia-architectureSkill
- elysiaSkill
- evlogSkill
- feedsmithSkill
- grokSkill
- handoffSkill
- heyapiSkill
- impitSkill
- intlayerSkill
- jsdocSkill
- kafkaSkill
- kill-legacySkill
- legend-stateSkill
- loopSkill
- mantine-hooksSkill
- mobbinSkill
- motionSkill
- oxfmtSkill
- oxlintSkill
- permixSkill
- plain-languageSkill
- playwrightSkill
- react-boundariesSkill
- react-emailSkill
- reactSkill
- reorganizeSkill
- researchSkill
- schema-dtsSkill
- sentrySkill
- seoSkill
- setup-competitors-mdSkill
- setup-copywriting-mdSkill
- setup-icp-mdSkill
- setup-project-mdSkill
- simplify-layoutSkill
- storybookSkill
- subagentsSkill
- tailwindSkill
- tailwind-variantsSkill
- takumiSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 2 are distinctive, and 6 are very specific to this project.
0
Common
Most of the 13 edited versions we read keep these.
2
Distinctive
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Use this skill when work touches TanStack Router, especially @tanstack/react-router, src/routes/, src/router.tsx, route tree generation, …
- Distinctive: line 25
Prefer file-based routing unless the repo already uses code-based routes or the user asks otherwise.
- Very specific: line 26
Treat routeTree.gen.ts as generated output.
- Very specific: line 28
Keep navigation typed. Do not build paths by interpolating params or query strings into to.
- Very specific: line 29
Every route that reads URL search state should declare validateSearch.
- Very specific: line 30
Use beforeLoad for route UX gates, redirects, and context enrichment.
- Very specific: line 31
Put route-shared dependencies in router context.
- Distinctive: line 37
Prefer the repo's existing checks.
“Common” is measured: kept by at least 6 in 10 of the 13 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
TanStack Router
Use this skill when work touches TanStack Router, especially @tanstack/react-router, src/routes/**, src/router.tsx, route tree generation, typed navigation, or route-owned data loading.
Workflow
- Inspect the local Router shape first:
- Package versions for
@tanstack/react-router,@tanstack/router-plugin, devtools, adapters, and any Query/SSR integration. - Routing mode: file-based, code-based, virtual file routes, or mixed.
- Route entrypoints:
src/routes/__root.tsx,src/router.tsx, generatedsrc/routeTree.gen.ts, app/client entry, and SSR entry if present. - Route options that affect behavior:
validateSearch,params,beforeLoad,loaderDeps,loader,pendingComponent,errorComponent,notFoundComponent,search.middlewares,staleTime,gcTime,preload, andssrintegration.
- Package versions for
- Refresh docs for current behavior, new versions, SSR, testing, route generation, or migrations. Start from source-map.md.
- For setup, installation, route-tree generation, file naming, and colocating non-route modules beside routes (
-components,-hooks,-lib, …), use setup-route-trees.md. - For links, navigation, params, search params, masks, and URL state, use navigation-url-state.md.
- For loaders, context, auth guards, Query integration, error/not-found boundaries, preloading, and deferred data, use loaders-context-errors.md.
- For SSR, deployment rewrites, testing, devtools, ESLint, and production checks, use production-testing.md.
Implementation Judgment
- Prefer file-based routing unless the repo already uses code-based routes or the user asks otherwise.
- Treat
routeTree.gen.tsas generated output. Do not hand-edit it; regenerate through the repo's bundler/CLI flow. - Colocate route-owned UI/hooks/helpers in hyphen-prefixed folders (
routeFileIgnorePrefix, default-). Do not leave unprefixed non-route files underroutes/. - Keep navigation typed. Do not build paths by interpolating params or query strings into
to; passto,params,search, andhashseparately. - Every route that reads URL search state should declare
validateSearch; useloaderDepsto expose only the search fields a loader actually uses. - Use
beforeLoadfor route UX gates, redirects, and context enrichment. Do not treat route guards as the private-data authorization boundary. - Put route-shared dependencies in router context; do not call React hooks directly inside
beforeLoadorloader. - Decide explicitly between Router's built-in SWR loader cache and an external cache such as TanStack Query. When Query owns freshness, set router preload stale time to
0and let Query dedupe. - Handle not-found resources in loaders with
notFound()so loader data stays correctly typed and UI avoids flicker.
Verification
Prefer the repo's existing checks. For meaningful Router changes, include the relevant subset:
- Route tree generation via dev/build or explicit Router CLI command.
- Typecheck for route references, params, search, loaders, and context.
- Focused tests for route matching, search validation, loaders, auth redirects, not-found/error boundaries, and navigation.
- Browser smoke for direct loads, client navigation, back/forward, refresh, and production rewrite behavior.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

