node-sass的版本是3.9.3
Please restart this script from an administrative PowerShell!
在當前powershell中執行下命令
Start-Process powershell -Verb runAs
npm:error MSB3428: 未能加載 Visual C++ 組件“VCBuild.exe”
MSBUILD : error MSB3428: 未能加載 Visual C++ 組件“VCBuild.exe”。要解決此問題,1) 安裝 .NET Framework 2.0 SDK;2) 安裝 Microsoft Visual Studio 2005;或 3) 如果將該組件安裝到了其他位置,請將其位置添加到系統路徑中。 [C:\Users\win\Desktop\vonic-master\node_modules\node-sass\build\binding.sln]
以管理員身份運行:Windows PowerShell,出現錯誤上面就是解決方法
npm install --global --production windows-build-tools
npm install -g node-gyp
安裝python,只能安裝python 2的版本,python3會失敗
更改源文件
由於我跳出去了,所以沒這步,一般還需要新建.npmrc文件
phantomjs_cdnurl=http://cnpmjs.org/downloads
sass_binary_site=https://npm.taobao.org/mirrors/node-sass/
registry=https://registry.npm.taobao.org
安裝node-sass
npm install node-sass@3.9.3 --save-dev
