【发布时间】:2022-01-08 21:00:21
【问题描述】:
您好,我删除了我的节点模块文件夹和我的包 lock.json 文件。
在运行npm install 时出现以下错误:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: burp-react-native@1.0.0
npm ERR! Found: prop-types@15.6.2
npm ERR! node_modules/prop-types
npm ERR! prop-types@"^15.6.2" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer prop-types@"^15.7.2" from react-native-fast-image@6.0.0
npm ERR! node_modules/react-native-fast-image
npm ERR! react-native-fast-image@"6.0.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /Users/drive/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/drive/.npm/_logs/2021-12-02T11_01_47_740Z-debug.log
我该如何解决这个问题?有什么想法吗?
【问题讨论】:
-
试试
npm install --legacy-peer-deps
标签: node.js react-native npm