随笔 - 47,  文章 - 1,  评论 - 2,  阅读 - 51381

报错:

PS G:\TestProject\test-pro1\vue-pro3-webpack> npm install sass-loader@10.0.1
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: my_learning0721@1.0.0
npm ERR! Found: webpack@3.12.0
npm ERR! node_modules/webpack
npm ERR! dev webpack@"^3.6.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer webpack@"^4.36.0 || ^5.0.0" from sass-loader@10.0.1
npm ERR! node_modules/sass-loader
npm ERR! sass-loader@"10.0.1" 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\GYF\AppData\Local\npm-cache\eresolve-report.txt for a full report.

 
 
主要是因为node-sass和sass-loader这些个版本冲突,然后我就先安装了一个sass,然后sass-loader在网上搜索几个常用的版本,挨个试了试,最终试到了一个成功的v7.3.1。
个人npm,vue,node配置:
 安装的sass,sass-loader:
 使用命令:
npm install sass@1.26.5
npm install sass-loader@7.3.1
posted on   bro阿柒  阅读(4850)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 使用C#创建一个MCP客户端
· 分享一个免费、快速、无限量使用的满血 DeepSeek R1 模型,支持深度思考和联网搜索!
· ollama系列1:轻松3步本地部署deepseek,普通电脑可用
· 基于 Docker 搭建 FRP 内网穿透开源项目(很简单哒)
· 按钮权限的设计及实现
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

点击右上角即可分享
微信分享提示