node版本
问题描述:
1. 拉取平台代码后,使用yarn install命令安装依赖,当前的node版本为16.17.0,但是报错
1 | error commander@12.0.0: The engine "node" is incompatible with this module. |
2. 尝试升级node版本为18.12.0后,再次执行yarn install,发现出现了新的报错
1 | error @achrinza/node-ipc@9.2.2: The engine "node" is incompatible with this module. |
3. 综上两点错误,说明升级node版本并不能解决问题,google该问题以求解决方案
解决方案:
使用 yarn config set ignore-engines true 命令来解决部分模块版本不兼容问题,然后使用yarn install --force命令安装相关依赖
yarn config set ignore-engines true
本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 Monster龙!