v4 版本对于存在自定义标签的 vue SFC 生成出错误的类型文件
Closed this issue · 0 comments
l246804 commented
Describe the bug
在将 vite-plugin-dts
更新到 v4
后导致对存在 标签的单文件组件生成错误的类型文件。
Reproduction
https://stackblitz.com/edit/test-dts?file=vite.config.ts
Steps to reproduce
在复现的项目内切换 vite.config.ts
注册的插件然后进行构建,V3 版本没有问题。
System Info
System:
OS: Windows 11 10.0.22631
CPU: (8) x64 11th Gen Intel(R) Core(TM) i5-1135G7 @ 2.40GHz
Memory: 1.06 GB / 15.66 GB
Binaries:
Node: 20.17.0 - ~\AppData\Local\pnpm\node.EXE
Yarn: 1.22.22 - ~\AppData\Local\pnpm\yarn.CMD
npm: 10.8.2 - ~\AppData\Local\pnpm\npm.CMD
pnpm: 9.6.0 - ~\AppData\Local\pnpm\pnpm.EXE
Browsers:
Edge: Chromium (128.0.2739.67)
Internet Explorer: 11.0.22621.3527
npmPackages:
@vitejs/plugin-vue: ^5.1.4 => 5.1.4
@vitejs/plugin-vue-jsx: ^4.0.1 => 4.0.1
vite: ^5.4.8 => 5.4.8
vite-plugin-dts: ^4.3.0 => 4.3.0
Validations
- Read the FAQ.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- The provided reproduction is a minimal reproducible example of the bug.