From 9980ff26e7ac713b32956740b9dd917e933513d5 Mon Sep 17 00:00:00 2001 From: Enrico Sacchetti Date: Mon, 21 Jul 2025 13:04:37 -0400 Subject: [PATCH 1/3] docs: link tsconfig sections to kit config --- documentation/docs/10-getting-started/30-project-structure.md | 2 +- documentation/docs/98-reference/54-types.md | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/documentation/docs/10-getting-started/30-project-structure.md b/documentation/docs/10-getting-started/30-project-structure.md index 64bae0a695c1..d84eb161800b 100644 --- a/documentation/docs/10-getting-started/30-project-structure.md +++ b/documentation/docs/10-getting-started/30-project-structure.md @@ -79,7 +79,7 @@ This file contains your Svelte and SvelteKit [configuration](configuration). ### tsconfig.json -This file (or `jsconfig.json`, if you prefer type-checked `.js` files over `.ts` files) configures TypeScript, if you added typechecking during `npx sv create`. Since SvelteKit relies on certain configuration being set a specific way, it generates its own `.svelte-kit/tsconfig.json` file which your own config `extends`. +This file (or `jsconfig.json`, if you prefer type-checked `.js` files over `.ts` files) configures TypeScript, if you added typechecking during `npx sv create`. Since SvelteKit relies on certain configuration being set a specific way, it generates its own `.svelte-kit/tsconfig.json` file which your own config `extends`. To make changes to top-level options such as `include`, we recommend extending the generated config; see [typscript configuration](/docs/kit/configuration#typescript) for details. ### vite.config.js diff --git a/documentation/docs/98-reference/54-types.md b/documentation/docs/98-reference/54-types.md index 608e08bf46e6..6e4325d12c2b 100644 --- a/documentation/docs/98-reference/54-types.md +++ b/documentation/docs/98-reference/54-types.md @@ -190,6 +190,8 @@ Others are required for SvelteKit to work properly, and should also be left unto } ``` +Use the [typescript configuration](/docs/kit/configuration#typescript) in `svelte.config.js` to extend or modify the generated `jsconfig.json`. + ## $lib This is a simple alias to `src/lib`, or whatever directory is specified as [`config.kit.files.lib`](configuration#files). It allows you to access common components and utility modules without `../../../../` nonsense. From 3bbaddee60e0fd886128bd08d9a34ea8656bfb95 Mon Sep 17 00:00:00 2001 From: Tee Ming Date: Tue, 22 Jul 2025 16:56:10 +0800 Subject: [PATCH 2/3] Apply suggestion from @eltigerchino --- documentation/docs/98-reference/54-types.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/docs/98-reference/54-types.md b/documentation/docs/98-reference/54-types.md index 6e4325d12c2b..b8877b9beb8b 100644 --- a/documentation/docs/98-reference/54-types.md +++ b/documentation/docs/98-reference/54-types.md @@ -190,7 +190,7 @@ Others are required for SvelteKit to work properly, and should also be left unto } ``` -Use the [typescript configuration](/docs/kit/configuration#typescript) in `svelte.config.js` to extend or modify the generated `jsconfig.json`. +Use the [`typescript.config` setting](configuration#typescript) in `svelte.config.js` to extend or modify the generated `tsconfig.json`. ## $lib From e83e206ccdaeb6268e75bc2b1ce4c5fc2d4c9493 Mon Sep 17 00:00:00 2001 From: Tee Ming Date: Tue, 22 Jul 2025 16:56:16 +0800 Subject: [PATCH 3/3] Apply suggestion from @eltigerchino --- documentation/docs/10-getting-started/30-project-structure.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/docs/10-getting-started/30-project-structure.md b/documentation/docs/10-getting-started/30-project-structure.md index d84eb161800b..95ab3fde3c72 100644 --- a/documentation/docs/10-getting-started/30-project-structure.md +++ b/documentation/docs/10-getting-started/30-project-structure.md @@ -79,7 +79,7 @@ This file contains your Svelte and SvelteKit [configuration](configuration). ### tsconfig.json -This file (or `jsconfig.json`, if you prefer type-checked `.js` files over `.ts` files) configures TypeScript, if you added typechecking during `npx sv create`. Since SvelteKit relies on certain configuration being set a specific way, it generates its own `.svelte-kit/tsconfig.json` file which your own config `extends`. To make changes to top-level options such as `include`, we recommend extending the generated config; see [typscript configuration](/docs/kit/configuration#typescript) for details. +This file (or `jsconfig.json`, if you prefer type-checked `.js` files over `.ts` files) configures TypeScript, if you added typechecking during `npx sv create`. Since SvelteKit relies on certain configuration being set a specific way, it generates its own `.svelte-kit/tsconfig.json` file which your own config `extends`. To make changes to top-level options such as `include` and `exclude`, we recommend extending the generated config; see the [`typescript.config` setting](configuration#typescript) for more details. ### vite.config.js