npm install 报错,解决 node-sass@4.14.1 安装失败问题

淘宝原镜像源: https://registry.npm.taobao.org 旧域名于2021年官方公告域名更换事件,已于2022年05月31日零时起停止服务,域名HTTPS证书于2024年1月22日正式到期,不可再用。已替换为 https://registry.npmmirror.com


报错信息:

javascript 复制代码
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.14.1 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.14.1 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

解决方法:

  1. 切换node版本node-v14+
  2. 切换镜像地址,安装node-sass
bash 复制代码
npm config set sass_binary_site=https://npmmirror.com/mirrors/node-sass

npm i node-sass
相关推荐
喵个咪2 分钟前
RushWind Admin — 多租户行级隔离与租户回收站:Viewer 三态、repo_shell! 与全域级联清除
后端·rust
喵个咪3 分钟前
RushWind CMS — 三服务拓扑:core 领域层、双 BFF 薄代理与一份契约的双面输出
后端·rust
8486981192 小时前
农业病虫害防治系统怎么加 AI?症状直调诊断与专家确认的双轨设计
毕业设计·springboot·langchain4j·ai 诊断·农业信息化
不积跬步无以至千里mmbb263 小时前
Rust内核开发核心入口解析
linux·rust
木头左1 天前
【浏览器自动化】用 CDP 接管本机 Chrome:从一个宿主迁到另一个宿主的设计与踩坑
node.js·浏览器自动化·cdp·技能化·踩坑实践
wflynn1 天前
GitHub 今日推荐|rust-anything:录制真实输入输出,渐进式重写热点函数到 Rust
rust·开源·github·cli·claude-code·agent-skills
cpolar技术支持2 天前
把 agent-autoloop 装在 Mac 上:用本机 Node 实跑一次「接活—提问—拍板—接着干」,再用 cpolar 把它的状态页开给不在工位的自己
node.js·内网穿透·cpolar·ai agent·agent-autoloop
天空'之城2 天前
016基于边缘计算的智能家居异常行为检测系统
毕业设计·智能家居·边缘计算·异常检测·esp 32
风笙9782 天前
[Rust] String 与 &str 详解
rust
风笙9782 天前
[Rust]复合类型
rust