如何在 ubuntu 上更新 npm/node?我不断收到错误消息

如何在 ubuntu 上更新 npm/node?我不断收到错误消息

我运行: npm install npm@latest -g 并得到:

npm ERR! code EBADENGINE
npm ERR! engine Unsupported engine
npm ERR! engine Not compatible with your version of node/npm: [email protected]
npm ERR! notsup Not compatible with your version of node/npm: [email protected]
npm ERR! notsup Required: {"node":"^18.17.0 || >=20.5.0"}
npm ERR! notsup Actual:   {"npm":"9.5.0","node":"v18.15.0"}

相关内容