This starts your app in development mode, rebuilding assets on file changes.
Editing and previewing the docs of TanStack projects locally
The documentations for all TanStack projects except for React Charts are hosted on https://tanstack.com, powered by this TanStack Router app.
In production, the markdown doc pages are fetched from the GitHub repos of the projects, but in development they are read from the local file system.
Follow these steps if you want to edit the doc pages of a project (in these steps we’ll assume it’s TanStack/form) and preview them locally :
Create a new directory called tanstack.
mkdir tanstack
Enter the directory and clone this repo and the repo of the project there.
cd tanstack
git clone git@github.com:TanStack/tanstack.com.git
git clone git@github.com:TanStack/form.git
[!NOTE]
Your tanstack directory should look like this:
tanstack/
|
+-- form/
|
+-- tanstack.com/
[!WARNING]
Make sure the name of the directory in your local file system matches the name of the project’s repo. For example, tanstack/form must be cloned into form (this is the default) instead of some-other-name, because that way, the doc pages won’t be found.
Enter the tanstack/tanstack.com directory, install the dependencies and run the app in dev mode:
cd tanstack.com
pnpm i
# The app will run on https://localhost:3000 by default
pnpm dev
Welcome to TanStack.com!
This site is built with TanStack Router!
It’s deployed automagically with Netlify!
Development
From your terminal:
This starts your app in development mode, rebuilding assets on file changes.
Editing and previewing the docs of TanStack projects locally
The documentations for all TanStack projects except for
React Charts
are hosted on https://tanstack.com, powered by this TanStack Router app. In production, the markdown doc pages are fetched from the GitHub repos of the projects, but in development they are read from the local file system.Follow these steps if you want to edit the doc pages of a project (in these steps we’ll assume it’s
TanStack/form
) and preview them locally :tanstack
.tanstack/tanstack.com
directory, install the dependencies and run the app in dev mode:tanstack/form/docs
.