Describe the bug
vite-plus aliases "vite": "npm:@voidzero-dev/vite-plus-core@0.2.6", so its defineConfig is typed against that package's UserConfig/Plugin, while apps and plugin packages (@tailwindcss/vite peers on ^5 || ^6 || ^7 || ^8) type against vite itself. Comparing the two structurally identical Plugin types overflows the checker's depth limit.
Consequence: no vite.config.ts in a Vite+ project can be type-checked, despite vp lint running typeCheck — configs have to go in ignorePatterns.
Reproduction
https://github.com/filipfalcon/mre-vite-plus-defineconfig-typed-plugin-excessive-stack-depth
Steps to reproduce
npm install
npm run check
- Observe the error reported against
vite.config.ts
System Info
Environment:
Version 24.18.0
Source lts
Tool Paths:
node /Users/johndoe/.vite-plus/js_runtime/node/24.18.0/bin/node
npm /Users/johndoe/.vite-plus/js_runtime/node/24.18.0/bin/npm
npx /Users/johndoe/.vite-plus/js_runtime/node/24.18.0/bin/npx
Local vite-plus:
vite-plus Not found
Tools:
vite Not found
rolldown Not found
vitest Not found
oxfmt Not found
oxlint Not found
oxlint-tsgolint Not found
tsdown Not found
Environment:
Package manager Not found
Node.js v24.18.0
Used Package Manager
npm
Logs
Validations
Describe the bug
vite-plusaliases"vite": "npm:@voidzero-dev/vite-plus-core@0.2.6", so itsdefineConfigis typed against that package'sUserConfig/Plugin, while apps and plugin packages (@tailwindcss/vitepeers on^5 || ^6 || ^7 || ^8) type againstviteitself. Comparing the two structurally identicalPlugintypes overflows the checker's depth limit.Consequence: no
vite.config.tsin a Vite+ project can be type-checked, despitevp lintrunningtypeCheck— configs have to go inignorePatterns.Reproduction
https://github.com/filipfalcon/mre-vite-plus-defineconfig-typed-plugin-excessive-stack-depth
Steps to reproduce
npm installnpm run checkvite.config.tsSystem Info
Used Package Manager
npm
Logs
Validations