0
Fork 0
mirror of https://github.com/TanStack/router.git synced 2026-11-16 19:38:07 +00:00
router/examples/solid/start-basic-auth
Sheraff fcddd16f20
chore(examples): ignore .tanstack/ in every Start example
The route generator writes its temporary files to .tanstack/tmp. Each
Start example now ignores the directory on its own, as a project copied
out of the monorepo (whose root ignores **/.tanstack). The five without a
.gitignore get start-basic's entries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
History 2026-11-09 15:00:55 +01:00
..
.devcontainer docs: add devcontainer.json to all e2e/examples (#6972) 2026-03-18 15:43:14 +01:00
.vscode test(solid-start): basic-auth e2e suite and example (#5558) 2025-10-21 03:53:40 +02:00
prisma update start-basic-auth project to prisma 7 (#5911) 2025-11-20 19:44:02 +01:00
public test(solid-start): basic-auth e2e suite and example (#5558) 2025-10-21 03:53:40 +02:00
src chore(examples): regenerate route trees through the example builds 2026-10-26 13:18:57 +01:00
.env test(solid-start): basic-auth e2e suite and example (#5558) 2025-10-21 03:53:40 +02:00
.gitignore chore(examples): ignore .tanstack/ in every Start example 2026-11-09 15:00:55 +01:00
.prettierignore test(solid-start): basic-auth e2e suite and example (#5558) 2025-10-21 03:53:40 +02:00
dev.db update start-basic-auth project to prisma 7 (#5911) 2025-11-20 19:44:02 +01:00
package.json ci: Version Packages (#8891) 2026-11-08 10:47:39 +01:00
prisma.config.ts update start-basic-auth project to prisma 7 (#5911) 2025-11-20 19:44:02 +01:00
README.md response reconciliation (#7588) 2026-10-13 00:01:04 +02:00
tsconfig.json chore: upgrade tooling to typescript 6 (#7024) 2026-03-23 22:59:52 +01:00
vite.config.ts docs: update examples/e2e to vite 8 (#6958) 2026-03-17 20:37:11 +01:00

Welcome to TanStack.com!

This site is built with TanStack Router!

It's deployed automagically with Netlify!

Development

From your terminal:

pnpm install
pnpm dev

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 :

  1. Create a new directory called tanstack.
mkdir tanstack
  1. 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.

  1. 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
  1. Now you can visit http://localhost:3000/form/latest/docs/overview in the browser and see the changes you make in tanstack/form/docs.

Note

The updated pages need to be manually reloaded in the browser.

Warning

You will need to update the docs/config.json file (in the project's repo) if you add a new doc page!

Session configuration

This example uses iron-session through Start's getCookie and setCookie helpers. Set SESSION_PASSWORD to a random secret of at least 32 characters before starting the app, for example:

export SESSION_PASSWORD="$(openssl rand -base64 32)"

Keep the same secret across instances and deployments that must read the same sessions. The cookie requires HTTPS in production. Each handler reads its own session, then awaits session.save() before redirecting or returning.