We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
项目目录
├─packages │ └─layout <------ pnpm build │ ├─dist │ ├─src │ ├─package.json │ └─vite.config.ts ├─play ├─package.json ├─tsconfig.json └─vite.config.ts
这是/packages/layout/vite.config的配置
/packages/layout/vite.config
import { resolve } from 'node:path'; import { defineConfig } from 'vite'; import vue from '@vitejs/plugin-vue'; import dts from 'vite-plugin-dts'; export default defineConfig({ build: { outDir: './dist', emptyOutDir: true, cssCodeSplit: true, sourcemap: true, lib: { formats: ['es'], entry: [resolve(__dirname, './src/index.ts')], } }, define: { 'process.env.NODE_ENV': '"production"' }, plugins: [vue(), dts()], });
似乎是入口文件读取错了,没有生成 index.d.ts 生成了 vite.config.d.ts
index.d.ts
vite.config.d.ts
暂无
pnpm up
cd ./packages/layout
pnpm build
System: OS: Windows 10 10.0.22621 CPU: (8) x64 11th Gen Intel(R) Core(TM) i5-1135G7 @ 2.40GHz Memory: 1.93 GB / 15.69 GB Binaries: Node: 16.20.0 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.19 - ~\AppData\Roaming\npm\yarn.CMD npm: 8.19.4 - C:\Program Files\nodejs\npm.CMD pnpm: 7.32.0 - ~\AppData\Roaming\npm\pnpm.CMD Browsers: Chrome: 117.0.5938.89 Edge: Spartan (44.22621.2283.0), Chromium (116.0.1938.81) Internet Explorer: 11.0.22621.1
The text was updated successfully, but these errors were encountered:
请提供一下复现项目。
Sorry, something went wrong.
https://github.com/kanocence/dts-demo
a7bab4d
新版收集文件的逻辑有一些变化,表现上基本是按照 TypeScript 原本的方式去收集(旧版并不是),所以建议你打包的时候最好在打包的 root 目录有 tsconfig.json 并指定好 include,或者直接使用插件选项的 include。
root
tsconfig.json
include
No branches or pull requests
Describe the bug
项目目录
这是
/packages/layout/vite.config
的配置似乎是入口文件读取错了,没有生成
index.d.ts
生成了vite.config.d.ts
Reproduction
暂无
Steps to reproduce
pnpm up
cd ./packages/layout
pnpm build
System Info
Validations
The text was updated successfully, but these errors were encountered: