bufanyun / hotgo

HotGo 是一个基于 vue 和 goframe2.0 开发的全栈前后端分离的开发基础平台和移动应用平台,集成jwt鉴权,动态路由,动态菜单,casbin鉴权,消息队列,定时任务等功能,提供多种常用场景文件,让您把更多时间专注在业务开发上。

Home Page:https://hotgo.facms.cn/admin

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

前端代码依赖冲突

wohenbushuang opened this issue · comments

root ➜ /workspaces/web $ npm install
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: @vitejs/plugin-vue@3.2.0
npm ERR! Found: vite@4.5.2
npm ERR! node_modules/vite
npm ERR!   dev vite@"^4.2.7" from the root project
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!   4 more (vite-plugin-html, vite-plugin-style-import, ...)
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer vite@"^3.0.0" from @vitejs/plugin-vue@3.2.0
npm ERR! node_modules/@vitejs/plugin-vue
npm ERR!   dev @vitejs/plugin-vue@"^3.2.0" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: vite@3.2.8
npm ERR! node_modules/vite
npm ERR!   peer vite@"^3.0.0" from @vitejs/plugin-vue@3.2.0
npm ERR!   node_modules/@vitejs/plugin-vue
npm ERR!     dev @vitejs/plugin-vue@"^3.2.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 install -g yarn
yarn install

try this, npm install --legacy-peer-deps