【问题标题】:"eslint-config-react-app" issue with create-react-app version 5create-react-app 版本 5 的“eslint-config-react-app”问题
【发布时间】:2022-01-19 19:03:39
【问题描述】:

我决定升级到 create-react-app 的新版本,然后我尝试通过“npm start”启动应用程序,只要它加载到屏幕上,就会弹出以下错误:

编译时出现问题:X 错误 插件“react”在“package.json » eslint-config-react-app » C:\Users\27par\Desktop\React Projects\development\finevines\node_modules\eslint-config-react-app\base.js”之间发生冲突和“BaseConfig » C:\Users\27par\Desktop\React Projects\Development\finevines\node_modules\eslint-config-react-app\base.js”。

错误图片: https://gyazo.com/a03be194379ea52e6d7ddd697eefb8aa

我想知道是否有其他人和我有同样的问题,是否有任何可能的解决方法。

谢谢。

【问题讨论】:

    标签: reactjs visual-studio-code create-react-app


    【解决方案1】:
    【解决方案2】:

    您需要更新所有软件包,就像eslint-config-react-apppackage.json 一样,它将具有create-react-app 的先前版本。所以,基本上错误是告诉你你正在更新到新版本,但是你项目中的其他库使用了另一个版本。

    尝试做 - npm run update

    【讨论】:

    • 这似乎有点帮助,非常感谢!
    【解决方案3】:

    只需尝试在文件夹根目录中的终端中运行 npm update 即可。 希望这行得通。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2018-08-10
      • 1970-01-01
      • 2019-09-13
      • 2020-02-28
      • 2020-04-14
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多