Yarn build ignores eslintConfig after using react-create-app

I created my own project with react-create-app. I saw the eslint error of eqeqeq in the process of Build. I want to ignore this warning message and see that the eslintConfig configuration in package.json can be solved, but I don"t see it coming into effect. Why?

tried to add configuration to pacakge.json, invalid

  "eslintConfig": {
    "extends": "react-app",
    "rules": {
      "eqeqeq": "off"
    }
  },

attempted to add .eslintrc.json file, invalid

{
  "rules": {
    "eqeqeq": "off"
  }
}

I found several articles saying that I don"t want to use react eject,. I don"t want to use eject. After eject, a large number of configurations need to be managed by myself, which is very troublesome.

I found that eslint is still valid in the start phase (during dev), but it is not valid in build. How can I make the eslint configuration of react take effect in the build phase?

Mar.28,2021

change that off to 0

.
{
  "rules": {
    "eqeqeq": 0
  }
}
Menu