-
Notifications
You must be signed in to change notification settings - Fork 8.6k
Closed
Labels
Description
Version
Vben Admin V5
Describe the bug?
只要更新依赖就然后, 构建的时候就会报这个错误, 是什么原因, 要删除要几次node modules, 才能构建成功
error during build: 11:56:46
../../node_modules/.pnpm/jiti@2.4.2/node_modules/jiti/lib/jiti.mjs (1:9): "createRequire" is not exported by "__vite-browser-external", imported by "../../node_modules/.pnpm/jiti@2.4.2/node_modules/jiti/lib/jiti.mjs".
file: /node_modules/.pnpm/jiti@2.4.2/node_modules/jiti/lib/jiti.mjs:1:9
1: import { createRequire } from "node:module";
Reproduction
偶现, 如我添加新的依赖进入package.json ,然后再重新执行, pnpm install , 最后执行pnpm build 则报错
System Info
构建环境 win10
node-v 22Relevant log output
Validations
- Read the docs
- Ensure the code is up to date. (Some issues have been fixed in the latest version)
- I have searched the existing issues and checked that my issue does not duplicate any existing issues.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.
Reactions are currently unavailable