简体   繁体   English

无法使用 npm 安装 gatsby-plugin-transition-link

[英]unable to install gatsby-plugin-transition-link with npm

在此处输入图像描述

Error report错误报告

I am unable to resolve this issue.我无法解决这个问题。 I have spent hours looking for a solution.我花了几个小时寻找解决方案。 I can't find one.我找不到一个。 Please help.请帮忙。 I know it's similar to the question here .我知道这与这里的问题相似。 But there is no method to solve there.但是那里没有解决方法。 Please help.请帮忙。

The issue is quite self-explanatory.这个问题是不言自明的。 You are running React on a version greater than 17.0.1 ( ^17.0.1 ), specifically the 17.0.2 and the dependency ( gatsby-plugin-transition-link ) needs the 16.8.5 .您在大于17.0.1 ( ^17.0.1 ) 的版本上运行 React,特别是17.0.2和依赖项 ( gatsby-plugin-transition-link ) 需要16.8.5

If downgrading React's version is not an option, you may need to review the migration guide (from v2 to v3 ) to install peer-dependencies, as some GitHub threads suggests .如果降级 React 的版本不是一个选项,您可能需要查看迁移指南(从v2v3以安装对等依赖项,正如一些GitHub 线程所建议的那样。

Check your outdated dependencies with:使用以下命令检查您过时的依赖项:

npm outdated

In addition, update your npm version to the lastest one by:此外,通过以下方式将您的npm版本更新到最新版本:

npm install -g npm

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM