更新node.js遇到錯誤:npm ERR! notsup Unsupported platform for n@7.3.0: wanted {"os":"!win32","arch":"any"} (current: {"os":"win32","arch":"x64"})


錯誤截圖:

PS D:\WEB前端\案例\vue_shop> npm install -g n        
npm ERR! code EBADPLATFORM
npm ERR! notsup Unsupported platform for n@7.3.0: wanted {"os":"!win32","arch":"any"} (current: {"os":"win32","arch":"x64"})  
npm ERR! notsup Valid OS:    !win32
npm ERR! notsup Valid Arch:  any
npm ERR! notsup Actual OS:   win32
npm ERR! notsup Actual Arch: x64

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\鄭燦佳\AppData\Roaming\npm-cache\_logs\2021-07-14T05_58_50_168Z-debug.log

解決辦法:

在npm命令npm install -g n后面添加 --force即可。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM