前端框架选型是企业提升开发效率与用户体验的关键因素
1338
2022-11-08
mac node-sass 安装错误
今天在安装node-sass的时候,出现了下面的错误:
(base) ➜ mall4v git:(master) ✗ npm install node-sass> node-sass@4.12.0 install /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass> node scripts/install.jsDownloading binary from download "error 404 Not FoundHint: If github.com is not accessible in your location try setting a proxy via HTTP_PROXY, e.g. export HTTP_PROXY=configure npm proxy via npm config set proxy node-sass@4.12.0 postinstall /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass> node scripts/build.jsBuilding: /usr/local/Cellar/node/13.11.0/bin/node /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=gyp info it worked if it ends with ok....
报了一大堆的错误,我的系统是mac。
解决方法
npm uninstall node-sassnpm install node-sass
就行了,我的日志为:
(base) ➜ mall4v git:(master) ✗ npm uninstall node-sassnpm notice created a lockfile as package-lock.json. You should commit this file.npm WARN sass-loader@6.0.6 requires a peer of node-sass@^4.0.0 but none is installed. You must install peer dependencies yourself.audited 1702 packages in 15.046s26 packages are looking for funding run `npm fund` for detailsfound 1057 vulnerabilities (55 low, 11 moderate, 990 high, 1 critical) run `npm audit fix` to fix them, or `npm audit` for details(base) ➜ mall4v git:(master) ✗ npm install node-sass> node-sass@4.14.1 install /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass> node scripts/install.jsDownloading binary from complete ⸩ ⠋ :Binary saved to /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass/vendor/darwin-x64-79/binding.nodeCaching binary to /Users/admin/.npm/node-sass/4.14.1/darwin-x64-79_binding.node> node-sass@4.14.1 postinstall /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass> node scripts/build.jsBinary found at /Users/admin/Documents/ccnu/mall4j/mall4v/node_modules/node-sass/vendor/darwin-x64-79/binding.nodeTesting binaryBinary is fine+ node-sass@4.14.1added 48 packages from 54 contributors and audited 1750 packages in 164.697s27 packages are looking for funding run `npm fund` for detailsfound 1059 vulnerabilities (55 low, 11 moderate, 992 high, 1 critical) run `npm audit fix` to fix them, or `npm audit` for details
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~