首页 > 其他分享 >vue2 router 安装

vue2 router 安装

时间:2023-01-21 14:00:25浏览次数:52  
标签:npm vue ERR -- dependency vue2 router 安装

报错

PS E:\ES6\vue2\vue_2\demo> npm install vue-router@4
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! Found: [email protected]
npm ERR! node_modules/vue
npm ERR!   vue@"^2.6.14" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer vue@"^3.2.0" from [email protected]
npm ERR! node_modules/vue-router
npm ERR!   vue-router@"4" 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! See C:\Users\keyter\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\keyter\AppData\Local\npm-cache\_logs\2023-01-21T05_25_33_325Z-debug-0.log
PS E:\ES6\vue2\vue_2\demo> npm install vue-router --save
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! Found: [email protected]
npm ERR! node_modules/vue
npm ERR!   vue@"^2.6.14" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer vue@"^3.2.0" from [email protected]
npm ERR! node_modules/vue-router
npm ERR!   vue-router@"*" 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! See C:\Users\keyter\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\keyter\AppData\Local\npm-cache\_logs\2023-01-21T05_45_03_692Z-debug-0.log
PS E:\ES6\vue2\vue_2\demo> npm i vue-router -S
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! Found: [email protected]
npm ERR! node_modules/vue
npm ERR!   vue@"^2.6.14" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer vue@"^3.2.0" from [email protected]
npm ERR! node_modules/vue-router
npm ERR!   vue-router@"*" 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! See C:\Users\keyter\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\keyter\AppData\Local\npm-cache\_logs\2023-01-21T05_47_41_052Z-debug-0.log

原因

:版本错误

使用建议版本

参考

标签:npm,vue,ERR,--,dependency,vue2,router,安装
From: https://www.cnblogs.com/jeseesmith/p/17063757.html

相关文章

  • Ubuntu 安装 Anaconda
    下载anaconda官网https://repo.anaconda.com/archive/国内镜像https://mirrors.bfsu.edu.cn/anaconda/archive/https://mirrors.xjtu.edu.cn/anaconda/archive/htt......
  • ubuntu 中 如何查看是否安装了ssh服务
     001、sudops-e|grepssh           ##如下界面提示没有安装  002、sudoservicesshstatus##查看ssh服务......
  • win11 安装 wsl lnux子系统
     001、win+r快捷键  002、输入control,点击确定,打开控制面板  003、点击程序  004、点击启用或关闭Windows功能   005、  ......
  • Linux Git安装&配置
    安装Git首先在Linux上安装Gitsudoapt-getinstallgit#Ubuntu/Debiansudoyuminstallgit#Centos/RedHat验证安装git--version配置Git增加用户(Github/Gite......
  • Ubuntu20.04/22.04 安装 Arduino IDE 2.x
    这周收到两片基于LGT8F328PLQFP32的ArduinoMiniEVB,机器上没有Arduino环境需要新安装,正好感受一下新出的ArduinoIDE2.x,记录一下Ubuntu20.04/22.04下安装A......
  • 如何安装win11
    1下载https://www.microsoft.com/zh-cn/software-download/windows11 ......
  • scoop 安装
    Powershell7安装的,普通用户和管理员安装路径不同,普通用户是默认安装在自己的路径下的,我的是win10用户目录Lenovo下。可以用来安装一些linux或者mac下好的应用,很方便。Set......
  • open-vm-tools-dkms : 依赖: open-vm-tools (>= 2:9.4.0-1280544-5ubuntu3) 但是它将
    参考文章:​​http://forum.ubuntu.org.cn/viewtopic.php?t=458707​​我的环境:XXX@Kylin:~/桌面$cat/proc/versionLinuxversion3.16.0-30-generic(buildd@phianna)(g......
  • ubuntu安装vlc
    参考官网:​​http://www.videolan.org/vlc/download-ubuntu.html​​看看官网的说明:VLCmediaplayerfor Ubuntu“SaucySalamander”Ubuntu13.04 “RaringRingtail......
  • Docker安装FileBrowser实现网页版文件管理器
    FileBrowser是一款基于现代浏览器技术的WEB版多用户文件管理器,它可以与我们的Aria2、qBittorrent等软件相结合,构建一个完整的离线下载与文件管理私有云。简单网盘,可以管理......