aleclarson / vite-tsconfig-paths

Support for TypeScript's path mapping in Vite
MIT License
1.3k stars 48 forks source link

Get Rid of References Override #82

Closed mssngr closed 1 year ago

mssngr commented 1 year ago

Vite, by default now, creates a tsconfig.node.json and adds a reference to it in the main tsconfig.json. This tsconfig.node.json is only intended for the vite.config.ts file, not for the source code. So, this offending block of code now discards the main tsconfig.json file for the ancillary tsconfig.node.json, causing several issues, including not using the baseUrl and paths from the main tsconfig.json. The result is a run like this:

  vite-tsconfig-paths projects: [ '/Users/gkonkle/dev/my-project/tsconfig.json' ] +1ms
  vite-tsconfig-paths config loaded: {
  configPath: '/Users/gkonkle/dev/my-project/tsconfig.node.json',

Removing this block should fix the above issue.

mssngr commented 1 year ago

This is to resolve an issue from #77 .

aleclarson commented 1 year ago

This PR removes project reference support, which is undesired.

Closed in favor of https://github.com/aleclarson/vite-tsconfig-paths/commit/99015bfc2f3dd9ae533d92f17f057c5f7572d27d