mirror of
https://github.com/TanStack/router.git
synced 2026-11-16 19:38:07 +00:00
🤖 A client-first, server-capable, fully type-safe router and full-stack framework for the web (React and more).
https://tanstack.com/router
framework
fullstack
javascript
react
route
router
routing
rpc
search
searchparams
server-functions
ssr
state-management
typesafe
typescript
url
- TypeScript 98.2%
- JavaScript 1.2%
- CSS 0.4%
- Vue 0.1%
- HTML 0.1%
`routerPackageStub` (a fake `@tanstack/{react,solid,vue}-router` with an
invented `.load()`) and `loadRouteOption` are gone (split F03): the
apps resolve the real built router packages, dependencies of this
package. New helpers of tests/dev-server.ts:
- `renderRoutePath(server, pathname)`: the real router over the generated
tree, `router.load()`, `<RouterProvider>` to HTML (SSR environment).
- `renderRouteComponent(component)`: React renders a component option
(after the real `preload()` when split).
- `servedRouterPackageUrl(server, target)`: the URL the client
environment serves the router package at (Vite's own resolver), the key
of its stub for `evaluateServed`.
- `importRouteModule` returns `{ server, routeModule }`.
`expectExportedRouteOptions` asserts outcomes: the export exists and is a
component; a split option is the real router's lazy component of it
(`preload`) rendering the same HTML; the page renders through the real
router. The pins that use it (known-bugs-dev-server: class and aliased
exports lost, shared overloads) fail without `.fails` on the missing
export (checked). `expectSharedOverloads` calls the real options.
Consumers (minimal edits in other owners' files): plugin-options.test.ts
(PO), router-plugin-context.test.ts (CTX), route-hmr.test.ts (W2-g:
Solid cases get `vite-plugin-solid` with `ssr: true`, which a Solid app's
SSR environment needs for the router's Solid build; the client evaluation
stubs the router with the SSR-loaded real package), dev-server-new-routes
(W2-f) and vite-hot-update.ts (W2-g deletes it): the router is served
from `/@fs/`, so the page-load skip patterns include it.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
History
|
|
|---|---|---|
| .agents/skills | ||
| .changeset | ||
| .devcontainer | ||
| .github | ||
| .nx/workflows | ||
| _artifacts | ||
| benchmarks | ||
| docs | ||
| e2e | ||
| examples | ||
| gpt | ||
| media | ||
| packages | ||
| scripts | ||
| skills/bundle-size-optimization | ||
| .coderabbit.yaml | ||
| .gitattributes | ||
| .gitignore | ||
| .npmrc | ||
| .nvmrc | ||
| .prettierignore | ||
| AGENTS.md | ||
| CONTRIBUTING.md | ||
| DEBUGGING.md | ||
| eslint.config.js | ||
| how-to-guides-implementation-plan.md | ||
| how-to-testing-plan.md | ||
| knip.json | ||
| labeler-config.yml | ||
| LICENSE | ||
| nx.json | ||
| package.json | ||
| pnpm-lock.yaml | ||
| pnpm-workspace.yaml | ||
| prettier.config.js | ||
| README.md | ||
| top-10-how-to-guides.md | ||
| tsconfig.json | ||
TanStack RouterA modern router designed for type safety, data‑driven navigation, and seamless developer experience.
Read the Router Docs → |
TanStack StartA full‑stack framework built on Router, designed for server rendering, streaming, and production‑ready deployments.
Read the Start Docs → |
Get Involved
- We welcome issues and pull requests!
- Participate in GitHub discussions
- Chat with the community on Discord
- See CONTRIBUTING.md for setup instructions
Partners
|
|
|
|
|
|
|
|
|
|
|
|
We're looking for TanStack Router & Start Partners to join our mission! Partner with us to push the boundaries of TanStack Router & Start and build amazing things together.
LET'S CHATExplore the TanStack Ecosystem
- TanStack Config – Tooling for JS/TS packages
- TanStack DB – Reactive sync client store
- TanStack DevTools – Unified devtools panel
- TanStack Form – Type‑safe form state
- TanStack Pacer – Debouncing, throttling, batching
- TanStack Query – Async state & caching
- TanStack Ranger – Range & slider primitives
- TanStack Store – Reactive data store
- TanStack Table – Headless datagrids
- TanStack Virtual – Virtualized rendering
… and more at TanStack.com »