use vite paths#9857
Open
jackkav wants to merge 1 commit intoKong:developfrom
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the Insomnia build tooling to rely on Vite/tsconfig path mapping and removes baseUrl from several tsconfig files.
Changes:
- Add
vite-tsconfig-pathsto the Insomnia Vite config and dev dependencies. - Remove
compilerOptions.baseUrlfrompackages/insomnia,packages/insomnia-api, and component docs tsconfig. - Update
package-lock.jsonto reflect the new dependency tree.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| packages/insomnia/vite.config.ts | Adds vite-tsconfig-paths plugin to resolve TS path aliases in Vite. |
| packages/insomnia/tsconfig.json | Removes baseUrl from compiler options. |
| packages/insomnia/package.json | Adds vite-tsconfig-paths to devDependencies. |
| packages/insomnia-component-docs/tsconfig.json | Removes baseUrl override block for editor-only tsconfig. |
| packages/insomnia-api/tsconfig.json | Removes baseUrl from compiler options. |
| package-lock.json | Adds vite-tsconfig-paths (and includes additional dependency resolution changes). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+56
to
+58
| viteTsconfigPaths({ | ||
| root: __dirname, | ||
| }), |
There was a problem hiding this comment.
vite-tsconfig-paths appears to be redundant here because the config already hard-codes the ~ alias via resolve.alias (same mapping as tsconfig.json's paths). Keeping both sources of truth can lead to drift/confusion; consider removing the manual alias (and using the plugin everywhere that needs it, e.g. Vitest) or dropping the plugin if the alias stays.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
remove deprecated baseUrl