Skip to content

Commit 111f193

Browse files
committed
docs: align agent skills with intent schema
1 parent 21c0e8b commit 111f193

30 files changed

Lines changed: 145 additions & 121 deletions

File tree

‎packages/react-router/skills/compositions/router-query/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
---
2-
name: compositions/router-query
2+
name: router-query
33
description: >-
44
Integrating TanStack Router with TanStack Query: queryClient
55
in router context, ensureQueryData/prefetchQuery in loaders,
66
useSuspenseQuery in components, defaultPreloadStaleTime: 0,
77
setupRouterSsrQueryIntegration for SSR dehydration/hydration
88
and streaming, per-request QueryClient isolation.
9-
type: composition
10-
library: tanstack-router
11-
library_version: '1.166.2'
9+
metadata:
10+
type: composition
11+
library: tanstack-router
12+
library_version: '1.166.2'
1213
requires:
1314
- router-core
1415
- router-core/data-loading

‎packages/react-router/skills/lifecycle/migrate-from-react-router/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
---
2-
name: lifecycle/migrate-from-react-router
2+
name: migrate-from-react-router
33
description: >-
44
Step-by-step migration from React Router v7 to TanStack Router:
55
route definition conversion, Link/useNavigate API differences,
66
useSearchParams to validateSearch + useSearch, useParams with from,
77
Outlet replacement, loader conversion, code splitting differences.
8-
type: lifecycle
9-
library: tanstack-router
10-
library_version: '1.166.2'
8+
metadata:
9+
type: lifecycle
10+
library: tanstack-router
11+
library_version: '1.166.2'
1112
requires:
1213
- router-core
1314
- react-router

‎packages/react-router/skills/react-router/SKILL.md‎

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,11 @@ description: >-
88
Outlet, CatchBoundary, ErrorComponent. React-specific patterns
99
for hooks, providers, SSR hydration, and createLink with
1010
forwardRef.
11-
type: framework
12-
library: tanstack-router
13-
library_version: '1.166.2'
14-
framework: react
11+
metadata:
12+
type: framework
13+
library: tanstack-router
14+
library_version: '1.166.2'
15+
framework: react
1516
requires:
1617
- router-core
1718
sources:
@@ -24,8 +25,6 @@ sources:
2425

2526
This skill builds on router-core. Read [router-core](../../../router-core/skills/router-core/SKILL.md) first for foundational concepts.
2627

27-
This skill covers the React-specific bindings, components, hooks, and setup for TanStack Router.
28-
2928
> **CRITICAL**: TanStack Router types are FULLY INFERRED. Never cast, never annotate inferred values.
3029
> **CRITICAL**: TanStack Router is CLIENT-FIRST. Loaders run on the client by default, not on the server.
3130
> **CRITICAL**: Do not confuse `@tanstack/react-router` with `react-router-dom`/`react-router`. They are completely different libraries with different APIs.

‎packages/react-start/skills/lifecycle/migrate-from-nextjs/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
---
2-
name: lifecycle/migrate-from-nextjs
2+
name: migrate-from-nextjs
33
description: >-
44
Step-by-step migration from Next.js App Router to TanStack Start:
55
route definition conversion, API mapping, server function
66
conversion from Server Actions, middleware conversion, data
77
fetching pattern changes.
8-
type: lifecycle
9-
library: tanstack-start
10-
library_version: '1.168.32'
8+
metadata:
9+
type: lifecycle
10+
library: tanstack-start
11+
library_version: '1.168.32'
1112
requires:
1213
- start-core
1314
- react-start

‎packages/react-start/skills/react-start/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,11 @@ description: >-
55
StartServer, React-specific imports, re-exports from
66
@tanstack/react-router, full project setup with React, useServerFn
77
hook.
8-
type: framework
9-
library: tanstack-start
10-
library_version: '1.168.32'
11-
framework: react
8+
metadata:
9+
type: framework
10+
library: tanstack-start
11+
library_version: '1.168.32'
12+
framework: react
1213
requires:
1314
- start-core
1415
sources:

‎packages/react-start/skills/react-start/server-components/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
name: react-start/server-components
2+
name: server-components
33
description: >-
44
Implement, review, debug, and refactor TanStack Start React Server
55
Components in React 19 apps. Use when tasks mention
@@ -12,9 +12,10 @@ description: >-
1212
migration from Next App Router RSC patterns. Do not use for
1313
generic SSR or non-TanStack RSC frameworks except brief
1414
comparison.
15-
type: sub-skill
16-
library: tanstack-start
17-
library_version: '1.168.32'
15+
metadata:
16+
type: sub-skill
17+
library: tanstack-start
18+
library_version: '1.168.32'
1819
requires:
1920
- react-start
2021
- start-core/server-functions

‎packages/router-core/skills/router-core/SKILL.md‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ description: >-
55
createRouter, createRoute, createRootRoute, createRootRouteWithContext,
66
addChildren, Register type declaration, route matching, route sorting,
77
file naming conventions. Entry point for all router skills.
8-
type: core
9-
library: tanstack-router
10-
library_version: '1.171.15'
8+
metadata:
9+
type: core
10+
library: tanstack-router
11+
library_version: '1.171.15'
1112
---
1213

1314
# TanStack Router Core

‎packages/router-core/skills/router-core/auth-and-guards/SKILL.md‎

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
---
2-
name: router-core/auth-and-guards
2+
name: auth-and-guards
33
description: >-
44
Route protection with beforeLoad, redirect()/throw redirect(),
55
isRedirect helper, authenticated layout routes (_authenticated),
66
non-redirect auth (inline login), RBAC with roles and permissions,
77
auth provider integration (Auth0, Clerk, Supabase), router context
88
for auth state.
9-
type: sub-skill
10-
library: tanstack-router
11-
library_version: '1.171.15'
9+
metadata:
10+
type: sub-skill
11+
library: tanstack-router
12+
library_version: '1.171.15'
1213
requires:
1314
- router-core
1415
sources:
@@ -438,8 +439,6 @@ export const Route = createFileRoute('/_authenticated/dashboard')({
438439
})
439440
```
440441

441-
`beforeLoad` runs before any component rendering and before the loader. It completely prevents the flash.
442-
443442
### HIGH: Not re-throwing redirects in try/catch
444443

445444
`redirect()` works by throwing. If `beforeLoad` has a try/catch, the redirect gets swallowed:

‎packages/router-core/skills/router-core/code-splitting/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
---
2-
name: router-core/code-splitting
2+
name: code-splitting
33
description: >-
44
Automatic code splitting (autoCodeSplitting), .lazy.tsx convention,
55
createLazyFileRoute, createLazyRoute, lazyRouteComponent, getRouteApi
66
for typed hooks in split files, codeSplitGroupings per-route override,
77
splitBehavior programmatic config, critical vs non-critical properties.
8-
type: sub-skill
9-
library: tanstack-router
10-
library_version: '1.171.15'
8+
metadata:
9+
type: sub-skill
10+
library: tanstack-router
11+
library_version: '1.171.15'
1112
requires:
1213
- router-core
1314
sources:

‎packages/router-core/skills/router-core/data-loading/SKILL.md‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
---
2-
name: router-core/data-loading
2+
name: data-loading
33
description: >-
44
Route loader option, loaderDeps for cache keys, staleTime/gcTime/
55
defaultPreloadStaleTime SWR caching, pendingComponent/pendingMs/
66
pendingMinMs, errorComponent/onError/onCatch, beforeLoad, router
77
context and createRootRouteWithContext DI pattern, router.invalidate,
88
Await component, deferred data loading with unawaited promises.
9-
type: sub-skill
10-
library: tanstack-router
11-
library_version: '1.171.15'
9+
metadata:
10+
type: sub-skill
11+
library: tanstack-router
12+
library_version: '1.171.15'
1213
requires:
1314
- router-core
1415
sources:

0 commit comments

Comments
 (0)