The engine “node“ is incompatible with this module.解决方法

安装依赖库报如下异常

bash 复制代码
[2/4] Fetching packages...
error marked@11.1.0: The engine "node" is incompatible with this module. Expected version ">= 18". Got "16.14.0"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

手动右键删除 node_modules 文件夹,清空了 npm 缓存:

bash 复制代码
npm cache clean --force

发现还是不行。

后来在网上找到了解决方案:忽略错误。

输入命令:

bash 复制代码
yarn config set ignore-engines true

再重新安装依赖,运行项目就可以了

相关推荐
AlfredZhao7 天前
npm 源切换:一条命令搞定
npm
@tangguo1238 天前
npm 和 yarn 配置说明
前端·javascript·npm·node.js·yarn
Gl�ria8 天前
Yarn NM 常驻Flink任务下线:stop/savepoint 释放容器
flink·yarn
钝挫力PROGRAMER12 天前
npx 与 npm 全局安装/更新/卸载
npm·npx·mcp·dsh
天若有情67314 天前
开源轻量双语工具|一键批量查询 NPM 包历史下载量,支持按作者批量统计
javascript·npm·github pages·开源工具·netlify·前端开源·npm克隆量
柚稚姐姐18 天前
npm install pnpm -g npm error code EACCES npm error syscall symlink
前端·npm·node.js
晴天1619 天前
npm install -f(--force)深度解析:作用原理、报错根源与风险避坑指南
前端·npm·node.js
晴天1619 天前
.npmrc 配置文件全解析:从换源到工程化的完整指南
npm·npmrc
晴天1620 天前
peerDependencies 全面解析:前端依赖生态的核心机制与实战指南
前端·npm
ha_lydms22 天前
HDFS 简介
大数据·hadoop·hdfs·yarn·调度·aliyun·计算