Repository: TanStack/router
Pull request #3678: feat(router-generator): disable formatting of routeTree
Author: login: honzahruby
Labels: name: documentation
description: Everything documentation related
name: package: router-generator
Created: 2025-03-06T10:56:48Z | Merged: 2025-03-07T21:06:39Z

Based on discussion in https://github.com/TanStack/router/discussions/3664, I'm adding an option to disable formatting of the generated routeTree. The file is not meant for human consuption and disabling the formatter can significantly speed up the route generation process.


Diff:
diff --git a/.prettierignore b/.prettierignore
index a234ee7bd19..d285f8937df 100644
--- a/.prettierignore
+++ b/.prettierignore
@@ -14,4 +14,5 @@ node_modules
 
 **/test-results
 **/tests/generator/file-modification/routes/(test)/*
+**/tests/generator/no-formatted-route-tree/routeTree.snapshot.ts
 /.nx/workspace-data
\ No newline at end of file
diff --git a/docs/router/api/file-based-routing.md b/docs/router/api/file-based-routing.md
index 62c7cb4bb17..0e165665c0b 100644
--- a/docs/router/api/file-based-routing.md
+++ b/docs/router/api/file-based-routing.md
@@ -25,6 +25,7 @@ The following options are available for configuring the file-based routing:
 - [`routeTreeFileHeader`](#routetreefileheader)
 - [`routeTreeFileFooter`](#routetreefilefooter)
 - [`disableManifestGeneration`](#disablemanifestgeneration)
+- [`enableRouteTreeFormatting`](#enableroutetreeformatting)
 
 > [!WARNING]
 > Do not set the `routeFilePrefix`, `routeFileIgnorePrefix`, or `routeFileIgnorePattern` options, to match any of the tokens used in the **File Naming Conventions** guide, or you may run into unexpected behavior.
@@ -206,3 +207,9 @@ By default, this value is set to:
 This option allows you to disable the generation of the manifest.
 
 By default, this value is set to `false`.
+
+### `enableRouteTreeFormatting`
+
+This option turns on the formatting function on the generated route tree file, which can be time-consuming for large projects.
+
+By default, this value is set to `true`.
diff --git a/packages/router-generator/src/config.ts b/packages/router-generator/src/config.ts
index 818405c6d01..b76b1d5af31 100644
--- a/packages/router-generator/src/config.ts
+++ b/packages/router-generator/src/config.ts
@@ -17,6 +17,7 @@ export const configSchema = z.object({
   addExtensions: z.boolean().optional().default(false),
   disableLogging: z.boolean().optional().default(false),
   disableManifestGeneration: z.boolean().optional().default(false),
+  enableRouteTreeFormatting: z.boolean().optional().default(true),
   __enableAPIRoutesGeneration: z.boolean().optional(), // Internal flag to be turned on for TanStack Start
   apiBase: z.string().optional().default('/api'),
   routeTreeFileHeader: z
diff --git a/packages/router-generator/src/generator.ts b/packages/router-generator/src/generator.ts
index 9b8b0b53d94..c847dbc6697 100644
--- a/packages/router-generator/src/generator.ts
+++ b/packages/router-generator/src/generator.ts
@@ -796,8 +796,12 @@ export async function generator(config: Config, root: string) {
   // Write the route tree file, if it has changed
   const routeTreeWriteResult = await writeIfDifferent(
     path.resolve(config.generatedRouteTree),
-    await format(existingRouteTreeContent, config),
-    await format(routeConfigFileContent, config),
+    config.enableRouteTreeFormatting
+      ? await format(existingRouteTreeContent, config)
+      : existingRouteTreeContent,
+    config.enableRouteTreeFormatting
+      ? await format(routeConfigFileContent, config)
+      : routeConfigFileContent,
     {
       beforeWrite: () => {
         logger.log(`🟡 Updating ${config.generatedRouteTree}`)
diff --git a/packages/router-generator/tests/generator.test.ts b/packages/router-generator/tests/generator.test.ts
index 220a1d00aea..daf787b2ec2 100644
--- a/packages/router-generator/tests/generator.test.ts
+++ b/packages/router-generator/tests/generator.test.ts
@@ -71,6 +71,9 @@ function rewriteConfigByFolderName(folderName: string, config: Config) {
     case 'no-manifest':
       config.disableManifestGeneration = true
       break
+    case 'no-formatted-route-tree':
+      config.enableRouteTreeFormatting = false
+      break
     case 'custom-tokens':
       config.indexToken = '_1nd3x'
       config.routeToken = '_r0ut3_'
diff --git a/packages/router-generator/tests/generator/no-formatted-route-tree/routeTree.snapshot.ts b/packages/router-generator/tests/generator/no-formatted-route-tree/routeTree.snapshot.ts
new file mode 100644
index 00000000000..3caaefda945
--- /dev/null
+++ b/packages/router-generator/tests/generator/no-formatted-route-tree/routeTree.snapshot.ts
@@ -0,0 +1,117 @@
+/* eslint-disable */
+
+// @ts-nocheck
+
+// noinspection JSUnusedGlobalSymbols
+
+// This file was automatically generated by TanStack Router.
+// You should NOT make any changes in this file as it will be overwritten.
+// Additionally, you should also exclude this file from your linter and/or formatter to prevent it from being checked or modified.
+
+// Import Routes
+
+import { Route as rootRoute } from './routes/__root'
+import { Route as IndexImport } from './routes/index'
+import { Route as NestedIndexImport } from './routes/nested/index'
+import { Route as NestedChildImport } from './routes/nested/child'
+
+// Create/Update Routes
+
+const IndexRoute = IndexImport.update({
+          id: '/',path: '/',getParentRoute: () => rootRoute
+        }as any)
+
+const NestedIndexRoute = NestedIndexImport.update({
+          id: '/nested/',path: '/nested/',getParentRoute: () => rootRoute
+        }as any)
+
+const NestedChildRoute = NestedChildImport.update({
+          id: '/nested/child',path: '/nested/child',getParentRoute: () => rootRoute
+        }as any)
+
+// Populate the FileRoutesByPath interface
+
+declare module '@tanstack/react-router' {
+  interface FileRoutesByPath {
+    '/': {
+          id: '/'
+          path: '/'
+          fullPath: '/'
+          preLoaderRoute: typeof IndexImport
+          parentRoute: typeof rootRoute
+        }
+'/nested/child': {
+          id: '/nested/child'
+          path: '/nested/child'
+          fullPath: '/nested/child'
+          preLoaderRoute: typeof NestedChildImport
+          parentRoute: typeof rootRoute
+        }
+'/nested/': {
+          id: '/nested/'
+          path: '/nested'
+          fullPath: '/nested'
+          preLoaderRoute: typeof NestedIndexImport
+          parentRoute: typeof rootRoute
+        }
+  }
+}
+
+// Create and export the route tree
+
+export interface FileRoutesByFullPath {
+  '/': typeof IndexRoute,'/nested/child': typeof NestedChildRoute,'/nested': typeof NestedIndexRoute
+}
+
+export interface FileRoutesByTo {
+  '/': typeof IndexRoute,'/nested/child': typeof NestedChildRoute,'/nested': typeof NestedIndexRoute
+}
+
+export interface FileRoutesById {
+  '__root__': typeof rootRoute,
+  '/': typeof IndexRoute,'/nested/child': typeof NestedChildRoute,'/nested/': typeof NestedIndexRoute
+}
+
+export interface FileRouteTypes {
+  fileRoutesByFullPath: FileRoutesByFullPath
+  fullPaths: '/'|'/nested/child'|'/nested'
+  fileRoutesByTo: FileRoutesByTo
+  to: '/'|'/nested/child'|'/nested'
+  id: '__root__'|'/'|'/nested/child'|'/nested/'
+  fileRoutesById: FileRoutesById
+}
+
+export interface RootRouteChildren {
+  IndexRoute: typeof IndexRoute,NestedChildRoute: typeof NestedChildRoute,NestedIndexRoute: typeof NestedIndexRoute
+}
+
+const rootRouteChildren: RootRouteChildren = {
+  IndexRoute: IndexRoute,NestedChildRoute: NestedChildRoute,NestedIndexRoute: NestedIndexRoute
+}
+
+export const routeTree = rootRoute._addFileChildren(rootRouteChildren)._addFileTypes<FileRouteTypes>()
+
+
+/* ROUTE_MANIFEST_START
+{
+  "routes": {
+    "__root__": {
+      "filePath": "__root.tsx",
+      "children": [
+        "/",
+        "/nested/child",
+        "/nested/"
+      ]
+    },
+    "/": {
+      "filePath": "index.tsx"
+    },
+    "/nested/child": {
+      "filePath": "nested/child.tsx"
+    },
+    "/nested/": {
+      "filePath": "nested/index.tsx"
+    }
+  }
+}
+ROUTE_MANIFEST_END */
\ No newline at end of file
diff --git a/packages/router-generator/tests/generator/no-formatted-route-tree/routes/__root.tsx b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/__root.tsx
new file mode 100644
index 00000000000..ab504e42e91
--- /dev/null
+++ b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/__root.tsx
@@ -0,0 +1 @@
+/** */
diff --git a/packages/router-generator/tests/generator/no-formatted-route-tree/routes/index.tsx b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/index.tsx
new file mode 100644
index 00000000000..ab504e42e91
--- /dev/null
+++ b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/index.tsx
@@ -0,0 +1 @@
+/** */
diff --git a/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/child.tsx b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/child.tsx
new file mode 100644
index 00000000000..ab504e42e91
--- /dev/null
+++ b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/child.tsx
@@ -0,0 +1 @@
+/** */
diff --git a/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/index.tsx b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/index.tsx
new file mode 100644
index 00000000000..ab504e42e91
--- /dev/null
+++ b/packages/router-generator/tests/generator/no-formatted-route-tree/routes/nested/index.tsx
@@ -0,0 +1 @@
+/** */


Reviews:
user: login: SeanCassiere
body: As much as the name is quite verbose, it's very explicit in what it says it's going to do. 

I'd probably keep it the same, or if anything shorten it down to `disableRouteTreeFormatting`.

---

Naming is hard 🫣
state: COMMENTED
author_association: MEMBER
submitted_at: 2025-03-06T19:44:18Z
user: login: SeanCassiere
state: CHANGES_REQUESTED
author_association: MEMBER
submitted_at: 2025-03-07T11:04:26Z
user: login: SeanCassiere
state: APPROVED
author_association: MEMBER
submitted_at: 2025-03-07T20:52:53Z

Review comments:
diff_hunk: @@ -202,3 +203,9 @@ By default, this value is set to:
 This option allows you to disable the generation of the manifest.
 
 By default, this value is set to `false`.
+
+### `disableGeneratedRouteTreeFormatting`
+
+This options turns off formatting of the generated route tree which can be time-consuming for large project.
path: docs/router/api/file-based-routing.md
user: login: SeanCassiere
body: ```suggestion
This option turns off the formatting function on the generated route tree file, which can be time-consuming for large projects.
```
created_at: 2025-03-06T19:35:45Z
author_association: MEMBER
diff_hunk: @@ -25,6 +25,7 @@ The following options are available for configuring the file-based routing:
 - [`routeTreeFileHeader`](#routetreefileheader)
 - [`routeTreeFileFooter`](#routetreefilefooter)
 - [`disableManifestGeneration`](#disablemanifestgeneration)
+- [`disableRouteTreeFormatting`](#disablegeneratedroutetreeformatting)
path: docs/router/api/file-based-routing.md
user: login: SeanCassiere
body: 👀
created_at: 2025-03-07T11:04:09Z
author_association: MEMBER

PR comments:
user: login: nx-cloud[bot]
created_at: 2025-03-06T10:57:11Z
body: 
View your [CI Pipeline Execution ↗](https://cloud.nx.app/cipes/67cb5cc3ae74b7356ac2d306?utm_source=pull-request&utm_medium=comment) for commit 83fdbe13cd9e0809f50e1c7e54d6172a185538d3.

| Command | Status | Duration | Result |
|---------|--------|----------:|--------|
| `nx affected --targets=test:eslint,test:unit,tes...` | ✅ Succeeded | 6m 32s | [View ↗](https://cloud.nx.app/runs/QT9mumJFO0?utm_source=pull-request&utm_medium=comment) |
| `nx run-many --target=build --exclude=examples/*...` | ✅ Succeeded | 45s | [View ↗](https://cloud.nx.app/runs/J2kWXhFzAi?utm_source=pull-request&utm_medium=comment) |

---

☁️ [Nx Cloud](https://cloud.nx.app?utm_source=pull-request&utm_medium=comment) last updated this comment at `2025-03-07 21:00:29` UTC

<!-- NX_CLOUD_APP_COMMENT_END -->
author_association: CONTRIBUTOR
user: login: pkg-pr-new[bot]
created_at: 2025-03-06T11:00:19Z
body: 
[Open in Stackblitz](https://pkg.pr.new/template/821fe266-351d-4631-a81f-96bc1f90dc07)
<details><summary><b>More templates</b></summary><p>

- [tanstack-router-react-example-authenticated-routes](https://pkg.pr.new/template/855ad4fe-8f7b-4bb3-a55f-516261fe85f6)
- [tanstack-router-react-example-authenticated-routes-firebase](https://pkg.pr.new/template/a36c27a1-7c3b-4210-8476-003e8e743d7b)
- [tanstack-router-react-example-basic](https://pkg.pr.new/template/02188a9f-0ec4-42d9-b307-67255cd4940e)
- [tanstack-router-react-example-basic-default-search-params](https://pkg.pr.new/template/fdd38810-b33b-4de3-a289-32392cdd7bcd)
- [tanstack-router-react-example-basic-file-based](https://pkg.pr.new/template/dec44fdb-4eb6-4954-9a86-e10071936e5f)
- [tanstack-router-react-example-react-query](https://pkg.pr.new/template/dcb406bd-93ff-47d9-ad75-03ba9596a84e)
- [tanstack-router-react-example-basic-react-query-file-based](https://pkg.pr.new/template/0cb67e52-8165-4992-a1bf-4033ad85960d)
- [tanstack-router-react-example-basic-ssr-file-based](https://pkg.pr.new/template/63923bea-f5bc-4799-91f2-cd8a1a32207e)
- [tanstack-router-react-example-basic-ssr-streaming-file-based](https://pkg.pr.new/template/daffe168-ebff-47e9-b0f4-51f965fc6dce)
- [tanstack-router-react-example-basic-virtual-file-based](https://pkg.pr.new/template/25c231e5-f089-4541-b71d-3ca1ae14872a)
- [tanstack-router-react-example-basic-virtual-inside-file-based](https://pkg.pr.new/template/d709a32e-cce6-489c-a13c-c7a516bfc1bb)
- [tanstack-router-react-example-deferred-data](https://pkg.pr.new/template/1dcf75f4-68f8-47f4-8020-a5e812673ece)
- [tanstack-router-react-example-kitchen-sink](https://pkg.pr.new/template/1be38cf1-4e8c-4d24-8fa3-07865e3252cf)
- [tanstack-router-react-example-kitchen-sink-file-based](https://pkg.pr.new/template/90dee37f-1137-419f-94a0-119fa5df50d8)
- [tanstack-router-react-example-kitchen-sink-react-query](https://pkg.pr.new/template/c0cbb155-5ad0-4e66-b099-13a8eddc132e)
- [tanstack-router-react-example-kitchen-sink-react-query-file-based](https://pkg.pr.new/template/5899d68e-88f5-4641-9fad-66c52e4588e5)
- [tanstack-router-react-example-large-file-based](https://pkg.pr.new/template/f1cc596d-f5af-4537-a568-9b99e5eae5a6)
- [tanstack-router-react-example-location-masking](https://pkg.pr.new/template/4a9d92d3-f421-449e-bd28-bda794dda6e7)
- [tanstack-router-react-example-navigation-blocking](https://pkg.pr.new/template/e234887f-df89-4f17-9a5d-b3ff6b930f8d)
- [tanstack-router-react-example-quickstart](https://pkg.pr.new/template/01d7375e-28ae-4dfc-9d7c-651d800a705d)
- [tanstack-router-react-example-quickstart-esbuild-file-based](https://pkg.pr.new/template/63845ff2-328e-4375-bf92-12a383a06bfa)
- [tanstack-router-react-example-quickstart-file-based](https://pkg.pr.new/template/77ce0335-1ad4-4301-accc-d2334d8e1784)
- [tanstack-router-react-example-quickstart-rspack-file-based](https://pkg.pr.new/template/bf5bfbab-b213-445e-a7a9-b28adce205d7)
- [tanstack-router-react-example-quickstart-webpack-file-based](https://pkg.pr.new/template/53b08a8c-0f9e-4927-89c9-e26898f756ad)
- [router-monorepo-react-query](https://pkg.pr.new/template/80575c6b-eee4-4c28-b8f3-7ac51688f795)
- [router-mono-simple](https://pkg.pr.new/template/60a93d88-ba7a-46e4-8c49-f37d0b431740)
- [router-mono-simple-lazy](https://pkg.pr.new/template/94c540ce-516c-4c2b-954d-555bd7ed7fb6)
- [tanstack-router-react-example-scroll-restoration](https://pkg.pr.new/template/c74f954b-91b8-4e15-b2c7-7a66075e271f)
- [tanstack-search-validator-adapters](https://pkg.pr.new/template/f56c01ea-9cb8-4a2c-94af-243ce0669409)
- [tanstack-start-example-bare](https://pkg.pr.new/template/28ca570d-1802-4de9-97da-a706646cca93)
- [tanstack-start-example-basic](https://pkg.pr.new/template/2d5a5f79-06f8-498b-9900-dd7895104cd3)
- [tanstack-start-example-basic-auth](https://pkg.pr.new/template/ad64a682-7618-49c6-89d9-b5d9a03d8424)
- [tanstack-start-example-basic-react-query](https://pkg.pr.new/template/2506eeb6-a3a5-43a4-9496-39daa5783e4e)
- [tanstack-start-example-basic-rsc](https://pkg.pr.new/template/8f63aefc-c748-4089-b94b-733e8a891a92)
- [tanstack-start-example-basic-static](https://pkg.pr.new/template/66373683-f061-476e-ae74-8a4b395a4e1d)
- [tanstack-start-example-clerk-basic](https://pkg.pr.new/template/e7fd8dd2-d64f-42f0-8c04-6c465b98047b)
- [tanstack-start-example-convex-trellaux](https://pkg.pr.new/template/38f6d41a-d917-4a74-b098-53527ead9039)
- [tanstack-start-example-counter](https://pkg.pr.new/template/c0a161dc-fa27-4105-8cb1-f868c6fbeee3)
- [tanstack-start-example-large](https://pkg.pr.new/template/69c550d4-cd8f-4296-bb44-ed6d62d9edda)
- [tanstack-start-example-material-ui](https://pkg.pr.new/template/885c74fa-d2e0-439e-8b92-2a9f42bdc22d)
- [tanstack-start-example-supabase-basic](https://pkg.pr.new/template/b997093e-2463-4913-b368-220764d874ce)
- [tanstack-start-example-trellaux](https://pkg.pr.new/template/3a22baba-8b5b-44de-a49e-f69074758543)
- [tanstack-router-react-example-with-framer-motion](https://pkg.pr.new/template/4ce93b7a-bc38-412a-a2bc-024c257a67ef)
- [tanstack-router-react-example-with-trpc](https://pkg.pr.new/template/f9ced796-82b1-45ef-a27f-11bf2a304460)
- [tanstack-router-react-example-with-trpc-react-query](https://pkg.pr.new/template/c902e442-8c07-4149-91b3-6b11cc4d45a1)
- [tanstack-router-solid-example-basic-file-based](https://pkg.pr.new/template/6c472f57-6930-4dd0-9670-a7a3109646c6)
- [tanstack-router-solid-example-basic-solid-query](https://pkg.pr.new/template/25b0d235-d01e-4254-9d8a-bce1c971d56f)
- [tanstack-router-solid-example-basic-solid-query-file-based](https://pkg.pr.new/template/174b60f9-f3e6-4123-bdcf-b873d01599f5)
- [tanstack-router-solid-example-kitchen-sink-file-based](https://pkg.pr.new/template/5aea51c8-ddef-4da4-bf93-62203c15924a)
- [tanstack-router-solid-example-quickstart-file-based](https://pkg.pr.new/template/b5eba725-0261-4467-8154-81fd84a6e2a1)
- [tanstack-solid-start-example-bare](https://pkg.pr.new/template/03d1dc32-5691-41fa-8093-463ab91f6bc5)

</p></details>
      
    


<details><summary><b>@tanstack/arktype-adapter</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/arktype-adapter@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/create-router</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/create-router@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/create-start</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/create-start@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/directive-functions-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/directive-functions-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/eslint-plugin-router</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/eslint-plugin-router@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/history</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/history@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-router</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-router@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-router-with-query</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-router-with-query@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-api-routes</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-api-routes@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-client</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-client@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-config</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-config@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-router-manifest</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-router-manifest@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-server</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-server@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-server-functions-client</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-server-functions-client@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-server-functions-fetcher</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-server-functions-fetcher@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-server-functions-handler</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-server-functions-handler@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/react-start-server-functions-ssr</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/react-start-server-functions-ssr@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-cli</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-cli@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-core</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-core@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-devtools</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-devtools@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-generator</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-generator@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-utils</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-utils@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/router-vite-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/router-vite-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/server-functions-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/server-functions-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-router</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-router@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-api-routes</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-api-routes@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-client</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-client@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-config</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-config@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-plugin</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-plugin@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-router-manifest</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-router-manifest@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-server</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-server@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-server-functions-client</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-server-functions-client@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-server-functions-fetcher</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-server-functions-fetcher@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-server-functions-handler</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-server-functions-handler@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/solid-start-server-functions-ssr</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/solid-start-server-functions-ssr@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/start</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/start@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/start-config</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/start-config@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/start-server-functions-server</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/start-server-functions-server@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/valibot-adapter</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/valibot-adapter@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/virtual-file-routes</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/virtual-file-routes@3678
```

</p></details>
      
    

<details><summary><b>@tanstack/zod-adapter</b></summary><p>

```
npm i https://pkg.pr.new/TanStack/router/@tanstack/zod-adapter@3678
```

</p></details>
      
    

_commit: <a href="https://github.com/TanStack/router/runs/38402362308"><code>83fdbe1</code></a>_

author_association: NONE
user: login: schiller-manuel
created_at: 2025-03-06T12:07:09Z
body: wouldnt we want to disable formatting by default?

also the config name is pretty long, how about just `formatRouteTree` ?
author_association: CONTRIBUTOR
user: login: SeanCassiere
created_at: 2025-03-06T21:53:42Z
body: > wouldnt we want to disable formatting by default?

This is actually interesting 🤔 

Maybe just `enableRouteTreeFormatting`  and have it be defaulted to `true`.

That'd actually be a good pattern going forward and to refactor for in v2. Don't disable, just enable. I'll probably use it for disabling route manifest generation by default.
author_association: MEMBER
user: login: honzahruby
created_at: 2025-03-07T09:14:38Z
body: Sounds good, but I don't really want to introduce a breaking change, so for now I will rename it to `disableRouteTreeFormatting` and update the docs. Hope that's okay with you 🙏 
author_association: CONTRIBUTOR
user: login: SeanCassiere
created_at: 2025-03-07T09:22:31Z
body: @honzahruby please rename to `enableRouteTreeFormatting` and default it to `true`. I'll be renaming the other `disable*` flags to `enable*`, with backwards compact whilst we are in the v1 cycle.

Your introduction here, won't be a breaking change since it's a new feature that'd be defaulted to  `true` which is the current behaviour.

For your use case, you can set it to `false` in your project.
author_association: MEMBER
user: login: SeanCassiere
created_at: 2025-03-07T21:07:00Z
body: @honzahruby thank you for this 🚀
author_association: MEMBER
user: login: honzahruby
created_at: 2025-03-07T21:09:35Z
body: Thanks for your help and support, I’m happy to see this land and speed up our project further 💪 
author_association: CONTRIBUTOR