pnpm报错如Runing this command will add the dependency to the workspace root所示

Running this command will add the dependency to the workspace root, which might not be what you want - if you really meant it, make it explicit by running this command again with the -w flag (or --workspace-root). If you don't want to see this warning anymore, you may set the ignore-workspace-root-check setting to true.
报错触发场景:当在采用pnpm搭建的menorepo项目根目录下执行pnpm dlx @eslint/create-config后会报错,原因是在根目录下安装依赖是不被允许,解决办法如下:

复制代码
pnpm config set ignore-workspace-root-check true

之后再在根目录下面安装依赖就不会报错了。

相关推荐
listhi5201 天前
利用React Hooks简化状态管理
前端·javascript·react.js
一点一木1 天前
🚀 2025 年 10 月 GitHub 十大热门项目排行榜 🔥
前端·人工智能·github
华仔啊1 天前
这个Vue3旋转菜单组件让项目颜值提升200%!支持多种主题,拿来即用
前端·javascript·css
非凡ghost1 天前
Adobe Lightroom安卓版(手机调色软件)绿色版
前端·windows·adobe·智能手机·软件需求
BestAns1 天前
Postman 平替?这款轻量接口测试工具,本地运行 + 批量回归超实用!
前端
专注前端30年1 天前
Webpack进阶玩法全解析(性能优化+高级配置)
前端·webpack·性能优化
烛阴1 天前
Lua世界的基石:变量、作用域与七大数据类型
前端·lua
张拭心1 天前
“不卷 AI、不碰币、下班不收消息”——Android 知名技术大牛 Jake Wharton 的求职价值观
android·前端·aigc
SoaringHeart1 天前
Flutter疑难解决:单独让某个页面的电池栏标签颜色改变
前端·flutter
Yeats_Liao1 天前
Go Web 编程快速入门 13 - 部署与运维:Docker容器化、Kubernetes编排与CI/CD
运维·前端·后端·golang