Skip to content

Commit 3e34b9f

Browse files
authored
"Clarify the 'Existing Projects' section of the TypeScript docs: (#52944)
> Add a sentence to the instructions for using typescript in an existing project instructing the user to copy the `paths` compiler option from the existing jsconfig file to the new tsconfig file. > Not doing so causes absolute imports from project directories to break, and gives "Module Not Found" messages that the docs do not have a case for solving"
1 parent 032e8d0 commit 3e34b9f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/02-app/01-building-your-application/06-configuring/01-typescript.mdx

+2
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ npx create-next-app@latest
2929

3030
Add TypeScript to your project by renaming a file to `.ts` / `.tsx`. Run `next dev` and `next build` to automatically install the necessary dependencies and add a `tsconfig.json` file with the recommended config options.
3131

32+
If you already had a `jsconfig.json` file, copy the `paths` compiler option from the old `jsconfig.json` into the new `tsconfig.json` file, and delete the old `jsconfig.json` file.
33+
3234
<AppOnly>
3335

3436
## TypeScript Plugin

0 commit comments

Comments
 (0)