安装npm install vuedraggable@next报错

npm install vuedraggable@next

npm ERR! code ERESOLVE npm ERR! ERESOLVE could not resolve npm ERR! npm ERR! While resolving: @vitejs/plugin-vue@3.1.0 npm ERR! Found: vite@5.4.20 npm ERR! node_modules/vite npm ERR! peer vite@">=2.0.0" from vite-plugin-compression@0.5.1 npm ERR! node_modules/vite-plugin-compression npm ERR! dev vite-plugin-compression@"^0.5.1" from the root project npm ERR! peer vite@">=2.0.0" from vite-plugin-svg-icons@2.0.1 npm ERR! node_modules/vite-plugin-svg-icons npm ERR! dev vite-plugin-svg-icons@"2.0.1" from the root project npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer vite@"^3.0.0" from @vitejs/plugin-vue@3.1.0 npm ERR! node_modules/@vitejs/plugin-vue npm ERR! dev @vitejs/plugin-vue@"3.1.0" from the root project npm ERR! npm ERR! Conflicting peer dependency: vite@3.2.11 npm ERR! node_modules/vite npm ERR! peer vite@"^3.0.0" from @vitejs/plugin-vue@3.1.0 npm ERR! node_modules/@vitejs/plugin-vue npm ERR! dev @vitejs/plugin-vue@"3.1.0" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution. npm ERR! npm ERR! npm ERR! For a full report see: npm ERR! D:\Program Files\nodejs\node_cache\_logs\2025-09-26T06_57_23_827Z-eresolve-report.txt npm ERR! A complete log of this run can be found in: D:\Program Files\nodejs\node_cache\_logs\2025-09-26T06_57_23_827Z-debug-0.log

问题:依赖冲突

解决办法:

复制代码
npm install vite@^5.0.0 @vitejs/plugin-vue@^5.0.0
npm install vuedraggable@next
相关推荐
猩猩程序员27 分钟前
Vercel 推出 Agent 框架 Eve:让 AI Agent 像写 Web 应用一样简单
前端
爱读源码的大都督1 小时前
Claude Code源码分析(三):为什么系统提示词中需要有tools呢?
前端·人工智能·后端
爱勇宝1 小时前
Claude Code 被曝暗藏“隐形检测”代码:封代理不是最可怕的,可怕的是你根本不知道它在干什么
前端·后端·程序员
小牛不牛的程序员1 小时前
我用 Claude Code 半天撸完了一个完整网站,AI 编程到底提升了多少效率?
前端
东风破_1 小时前
JavaScript 面试常考的字符串算法:从反转字符串到回文判断
前端·javascript
ITOM运维行者1 小时前
从零搭建企业级服务器监控体系:踩坑实录与架构设计
前端·后端
monologues1 小时前
深入 Vue 3 源码:响应式系统的精妙设计与编译优化
前端
hunterandroid1 小时前
Paging 3 分页:从手动分页到声明式加载
前端
用户4099322502122 小时前
Vue状态管理入门第四章:组合式store和SSR风险
前端·vue.js·后端
Csvn2 小时前
CSS :has() 选择器实战:没有它之前我们写了多少冗余 JS
前端·css