0

i want to fix this issue without using --force ,--legacy-peer-deps commands . since i am new to dependency update can anyone explain this concept and give me a solution to update this versions. i got this error when i am trying to install prettier libraries .

npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: eslint-config-airbnb-base@14.2.1
npm ERR! Found: eslint@8.35.0
npm ERR! node_modules/eslint
npm ERR!   peer eslint@">= 4.12.1" from babel-eslint@10.1.0
npm ERR!   node_modules/babel-eslint
npm ERR!     dev babel-eslint@"^10.1.0" from the root project
npm ERR!   peer eslint@"^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" from eslint-plugin-import@2.26.0
npm ERR!   node_modules/eslint-plugin-import
npm ERR!     peer eslint-plugin-import@"^2.22.1" from eslint-config-airbnb-base@14.2.1
npm ERR!     node_modules/eslint-config-airbnb-base
npm ERR!       dev eslint-config-airbnb-base@"^14.2.1" from the root project
npm ERR!     dev eslint-plugin-import@"^2.22.1" from the root project
npm ERR!   3 more (eslint-utils, the root project, eslint-plugin-prettier)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@"^5.16.0 || ^6.8.0 || ^7.2.0" from eslint-config-airbnb-base@14.2.1
npm ERR! node_modules/eslint-config-airbnb-base
npm ERR!   dev eslint-config-airbnb-base@"^14.2.1" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: eslint@7.32.0
npm ERR! node_modules/eslint
npm ERR!   peer eslint@"^5.16.0 || ^6.8.0 || ^7.2.0" from eslint-config-airbnb-base@14.2.1
npm ERR!   node_modules/eslint-config-airbnb-base
npm ERR!     dev eslint-config-airbnb-base@"^14.2.1" 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 C:\Users\ssss\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\ssss\AppData\Local\npm-cache\_logs\2023-03-09T02_48_26_533Z-debug-0.log

Dev Dependencies

    "@babel/cli": "^7.13.14",
    "@babel/core": "^7.13.14",
    "@babel/plugin-transform-runtime": "^7.13.10",
    "@babel/preset-env": "^7.13.12",
    "@sysco/jest-qcenter-integrator": "^2.0.2",
    "babel-eslint": "^10.1.0",
    "babel-loader": "^8.2.2",
    "babel-plugin-source-map-support": "^2.1.3",
    "babel-plugin-transform-object-rest-spread": "^6.26.0",
    "copy-webpack-plugin": "^6.2.1",
    "cross-env": "^7.0.3",
    "eslint": "^8.34.0",
    "eslint-config-airbnb-base": "^14.2.1",
    "eslint-loader": "^3.0.4",
    "eslint-plugin-import": "^2.22.1",
    "husky": "^3.0.5",
    "jest": "^28.1.0",
    "lint-staged": "^9.5.0",
V2rson
  • 137
  • 1
  • 10

0 Answers0