Open History to see the last commit
1# Create React App for TanStack Router
2
3This CLI application builds Tanstack Router applications that are the functional equivalent of [Create React App](https://create-react-app.dev/).
4
5To help accelerate the migration away from `create-react-app` we created the `create-start-app` CLI which is a plug-n-play replacement for CRA.
6
7## Quick Start
8
9To maintain compatability with `create-react-app` you can build a new application by running:
10
11| Command | Description |
12| ------------------------------------------------------- | ------------------ |
13| `pnpm dlx create-start-app@latest my-app` | Create a new app |
14| `pnpm dlx create-start-app@latest my-app --framework solid` | Create a Solid app |
15
16If you don't specify a project name, the CLI will walk you through an interactive setup process:
17
18```bash
19pnpm dlx create-start-app@latest
20```
21
22This will start an interactive CLI that guides you through the setup process, allowing you to choose:
23
24- Project Name
25- Package manager
26- Toolchain
27- Git initialization
28
29## Command Line Options
30
31You can also use command line flags to specify your preferences directly:
32
33```bash
34pnpm dlx create-start-app@latest my-app --package-manager pnpm
35```
36
37Available options:
38
39- `--package-manager`: Specify your preferred package manager (`npm`, `yarn`, `pnpm`, `bun`, or `deno`)
40- `--toolchain`: Specify your toolchain solution for formatting/linting (`biome`, `eslint`)
41- `--no-git`: Do not initialize a git repository
42- `--add-ons`: Enable add-on selection or specify add-ons to install
43- `--tailwind` / `--no-tailwind`: Deprecated compatibility flags; accepted but ignored (Tailwind is always enabled)
44
45When using flags, the CLI will display which options were provided and only prompt for the remaining choices.
46
47## Features
48
49What you'll get is a Vite application that uses TanStack Router. All the files will still be in the same place as in CRA, but you'll get a fully functional Router setup under in `app/main.tsx`.
50
51`create-start-app` is everything you loved about CRA but implemented with modern tools and best practices, on top of the popular TanStack set of libraries. Which includes [@tanstack/react-query](https://tanstack.com/query/latest) and [@tanstack/react-router](https://tanstack.com/router/latest).
52
53## Additional Configuration
54
55### Package Manager
56
57Choose your preferred package manager (`npm`, `bun`, `yarn`, `pnpm`, or `deno`) either through the interactive CLI or using the `--package-manager` flag.
58
59Extensive documentation on using the TanStack Start, as well as integrating [@tanstack/react-query](https://tanstack.com/query/latest) and [@tanstack/store](https://tanstack.com/store/latest) can be found in the generated `README.md` for your project.
60
61### Toolchain
62
63Choose your preferred solution for formatting and linting either through the interactive CLI or using the `--toolchain` flag.
64
65Setting this flag to `biome` will configure it as your toolchain of choice, adding a `biome.json` to the root of the project. Consult the [biome documentation](https://biomejs.dev/guides/getting-started/) for further customization.
66
67Setting this flag to `eslint` will configure it as your toolchain of choice, adding an `eslint.config.js` and `prettier.config.js` to the root of the project, as well as a `.prettierignore` file. Consult the [eslint documentation](https://eslint.org/docs/latest/) and [prettier documentation](https://prettier.io/docs/) for further customization.
68
69## Add-ons (experimental)
70
71You can enable add-on selection:
72
73```bash
74pnpm dlx create-start-app@latest --add-ons
75```
76
77This will prompt you to select the add-ons you want to enable during application creation.
78
79You can enable specific add-ons directly by adding a comma separated list of add-on names to the `--add-ons` flag. For example:
80
81```bash
82pnpm dlx create-start-app@latest my-app --add-ons shadcn,tanstack-query
83```
84
85You can get a list of all available add-ons by running:
86
87```bash
88pnpm dlx create-start-app@latest --list-add-ons
89```
90
91This will get you a list of all available add-ons for Solid.
92
93```bash
94pnpm dlx create-start-app@latest --list-add-ons --framework solid
95```
96
97## Agent Usage
98
99The CLI no longer includes an MCP server. Use direct CLI introspection commands instead:
100
101```bash
102pnpm dlx create-start-app@latest --list-add-ons
103pnpm dlx create-start-app@latest --addon-details tanstack-query
104```
105
106# Contributing
107
108Check out the [Contributing](CONTRIBUTING.md) guide.
109
110# License
111
112MIT