node.js – React-Native with Expo. I don´t undestand these errors

I am developing a mobile app with React-Native with Expo. I followed a tutorial on Youtube to start with the packages and installation. In the video the man uses a Eslint configuration, when I tried to do the same error messages began to pop-up in the terminal. I just simply tried to run it and it worked fine. I wanna know why this appear and if I could do something to resolve this.

Here is my package-lock.json (the code with the babel or eslint mentions).

{
  "name": "xxx",
  "version": "1.0.0",
  "lockfileVersion": 2,
  "requires": true,
  "packages": {
    "": {
      "name": "xxx",
      "version": "1.0.0",
      "dependencies": {
        "@react-native-masked-view/masked-view": "0.2.6",
        "@react-navigation/material-top-tabs": "^6.2.1",
        "@react-navigation/native": "^6.0.10",
        "@react-navigation/stack": "^6.2.1",
        "@rneui/base": "^4.0.0-rc.2",
        "@rneui/themed": "^4.0.0-rc.2",
        "@types/react": "~17.0.21",
        "accordion-collapse-react-native": "^1.1.1",
        "expo": "^45.0.6",
        "expo-av": "~11.2.3",
        "expo-status-bar": "~1.3.0",
        "expo-updates": "~0.13.2",
        "lodash.filter": "^4.6.0",
        "react": "17.0.2",
        "react-dom": "17.0.2",
        "react-native": "0.68.2",
        "react-native-gesture-handler": "~2.2.1",
        "react-native-image-pan-zoom": "^2.1.12",
        "react-native-maps": "0.30.2",
        "react-native-modal": "^13.0.1",
        "react-native-pager-view": "5.4.15",
        "react-native-reanimated": "~2.8.0",
        "react-native-safe-area-context": "4.2.4",
        "react-native-screens": "~3.11.1",
        "react-native-tab-view": "^3.1.1",
        "react-native-table-component": "^1.2.0",
        "react-native-web": "0.17.7",
        "react-native-webview": "11.18.1"
      },
      "devDependencies": {
        "@babel/core": "^7.12.9",
        "babel-eslint": "^10.1.0",
        "eslint-config-standard": "^17.0.0",
        "eslint-config-standard-jsx": "^11.0.0",
        "eslint-config-standard-react": "^11.0.1",
        "eslint-plugin-import": "^2.26.0",
        "eslint-plugin-node": "^11.1.0",
        "eslint-plugin-promise": "^6.0.0",
        "eslint-plugin-react": "^7.29.4"
      }
    },
    "node_modules/eslint-config-standard-react": {
      "version": "11.0.1",
      "resolved": "https://registry.npmjs.org/eslint-config-standard-react/-/eslint-config-standard-react-11.0.1.tgz",
      "integrity": "sha512-4WlBynOqBZJRaX81CBcIGDHqUiqxvw4j/DbEIICz8QkMs3xEncoPgAoysiqCSsg71X92uhaBc8sgqB96smaMmg==",
      "dev": true,
      "funding": [
        {
          "type": "github",
          "url": "https://github.com/sponsors/feross"
        },
        {
          "type": "patreon",
          "url": "https://www.patreon.com/feross"
        },
        {
          "type": "consulting",
          "url": "https://feross.org/support"
        }
      ],
      "peerDependencies": {
        "eslint": "^7.12.1",
        "eslint-plugin-react": "^7.21.5"
      }
    },
    "eslint-config-standard-react": {
      "version": "11.0.1",
      "resolved": "https://registry.npmjs.org/eslint-config-standard-react/-/eslint-config-standard-react-11.0.1.tgz",
      "integrity": "sha512-4WlBynOqBZJRaX81CBcIGDHqUiqxvw4j/DbEIICz8QkMs3xEncoPgAoysiqCSsg71X92uhaBc8sgqB96smaMmg==",
      "dev": true,
      "requires": {}
    },
    "node_modules/babel-eslint": {
      "version": "10.1.0",
      "resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.1.0.tgz",
      "integrity": "sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg==",
      "deprecated": "babel-eslint is now @babel/eslint-parser. This package will no longer receive updates.",
      "dev": true,
      "dependencies": {
        "@babel/code-frame": "^7.0.0",
        "@babel/parser": "^7.7.0",
        "@babel/traverse": "^7.7.0",
        "@babel/types": "^7.7.0",
        "eslint-visitor-keys": "^1.0.0",
        "resolve": "^1.12.0"
      },
      "engines": {
        "node": ">=6"
      },
      "peerDependencies": {
        "eslint": ">= 4.12.1"
      }
    },
    "babel-eslint": {
      "version": "10.1.0",
      "resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.1.0.tgz",
      "integrity": "sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg==",
      "dev": true,
      "requires": {
        "@babel/code-frame": "^7.0.0",
        "@babel/parser": "^7.7.0",
        "@babel/traverse": "^7.7.0",
        "@babel/types": "^7.7.0",
        "eslint-visitor-keys": "^1.0.0",
        "resolve": "^1.12.0"
      }
    },

Here is my package.json

{
  "name": "xxx",
  "version": "1.0.0",
  "main": "node_modules/expo/AppEntry.js",
  "scripts": {
    "start": "expo start",
    "android": "expo start --android",
    "ios": "expo start --ios",
    "web": "expo start --web",
    "eject": "expo eject"
  },
  "dependencies": {
    "@react-native-masked-view/masked-view": "0.2.6",
    "@react-navigation/material-top-tabs": "^6.2.1",
    "@react-navigation/native": "^6.0.10",
    "@react-navigation/stack": "^6.2.1",
    "@rneui/base": "^4.0.0-rc.2",
    "@rneui/themed": "^4.0.0-rc.2",
    "@types/react": "~17.0.21",
    "accordion-collapse-react-native": "^1.1.1",
    "expo": "^45.0.6",
    "expo-av": "~11.2.3",
    "expo-status-bar": "~1.3.0",
    "expo-updates": "~0.13.2",
    "lodash.filter": "^4.6.0",
    "react": "17.0.2",
    "react-dom": "17.0.2",
    "react-native": "0.68.2",
    "react-native-gesture-handler": "~2.2.1",
    "react-native-image-pan-zoom": "^2.1.12",
    "react-native-maps": "0.30.2",
    "react-native-modal": "^13.0.1",
    "react-native-pager-view": "5.4.15",
    "react-native-reanimated": "~2.8.0",
    "react-native-safe-area-context": "4.2.4",
    "react-native-screens": "~3.11.1",
    "react-native-tab-view": "^3.1.1",
    "react-native-table-component": "^1.2.0",
    "react-native-web": "0.17.7",
    "react-native-webview": "11.18.1"
  },
  "devDependencies": {
    "@babel/core": "^7.12.9",
    "babel-eslint": "^10.1.0",
    "eslint-config-standard": "^17.0.0",
    "eslint-config-standard-jsx": "^11.0.0",
    "eslint-config-standard-react": "^11.0.1",
    "eslint-plugin-import": "^2.26.0",
    "eslint-plugin-node": "^11.1.0",
    "eslint-plugin-promise": "^6.0.0",
    "eslint-plugin-react": "^7.29.4"
  },
  "private": true,
  "eslintConfig": {
    "parser": "@babel-eslint",
    "extends": [
      "standard",
      "standard-jsx",
      "standard-react"
    ],
    "rules": {
      "react/prop-types": "off"
    }
  }
}

And the output from the terminal

PS C:UsersxxxDocumentsxxxxxx> npm install
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: eslint-config-standard-react@11.0.1
npm ERR! Found: eslint@8.18.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@"^8.0.1" from eslint-config-standard@17.0.0
npm ERR!   node_modules/eslint-config-standard
npm ERR!     dev eslint-config-standard@"^17.0.0" from the root project
npm ERR!   10 more (eslint-config-standard-jsx, eslint-plugin-es, ...)
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@"^7.12.1" from eslint-config-standard-react@11.0.1
npm ERR! node_modules/eslint-config-standard-react
npm ERR!   dev eslint-config-standard-react@"^11.0.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@"^7.12.1" from eslint-config-standard-react@11.0.1
npm ERR!   node_modules/eslint-config-standard-react
npm ERR!     dev eslint-config-standard-react@"^11.0.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:UsersxxxAppDataLocalnpm-cacheeresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:UsersxxxAppDataLocalnpm-cache_logs2022-07-01T13_57_30_035Z-debug-0.log

Here is also the log that mentions:

    0 verbose cli C:Program Filesnodejsnode.exe C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js
    1 info using npm@8.11.0
    2 info using node@v16.15.1
    3 timing npm:load:whichnode Completed in 0ms
    4 timing config:load:defaults Completed in 2ms
    5 timing config:load:file:C:Program Filesnodejsnode_modulesnpmnpmrc Completed in 8ms
    6 timing config:load:builtin Completed in 8ms
    7 timing config:load:cli Completed in 1ms
    8 timing config:load:env Completed in 1ms
    9 timing config:load:file:C:UsersjbocciDocumentsGitHubMendozaCiudadReactNativeApp.npmrc Completed in 1ms
    10 timing config:load:project Completed in 3ms
    11 timing config:load:file:C:Usersjbocci.npmrc Completed in 0ms
    12 timing config:load:user Completed in 0ms
    13 timing config:load:file:C:UsersjbocciAppDataRoamingnpmetcnpmrc Completed in 0ms
    14 timing config:load:global Completed in 1ms
    15 timing config:load:validate Completed in 0ms
    16 timing config:load:credentials Completed in 1ms
    17 timing config:load:setEnvs Completed in 1ms
    18 timing config:load Completed in 18ms
    19 timing npm:load:configload Completed in 18ms
    20 timing npm:load:mkdirpcache Completed in 1ms
    21 timing npm:load:mkdirplogs Completed in 0ms
    22 verbose title npm install
    23 verbose argv "install"
    24 timing npm:load:setTitle Completed in 1ms
    25 timing config:load:flatten Completed in 4ms
    26 timing npm:load:display Completed in 6ms
    27 verbose logfile logs-max:10 dir:C:UsersjbocciAppDataLocalnpm-cache_logs
    28 verbose logfile C:UsersjbocciAppDataLocalnpm-cache_logs2022-07-01T13_57_30_035Z-debug-0.log
    29 timing npm:load:logFile Completed in 11ms
    30 timing npm:load:timers Completed in 0ms
    31 timing npm:load:configScope Completed in 0ms
    32 timing npm:load Completed in 38ms
    33 timing arborist:ctor Completed in 0ms
    34 silly logfile start cleaning logs, removing 2 files
    35 silly logfile done cleaning log files
    36 timing idealTree:init Completed in 839ms
    37 timing idealTree:userRequests Completed in 0ms
    38 silly idealTree buildDeps
    39 timing idealTree:#root Completed in 0ms
    40 silly fetch manifest eslint@^7.12.1
    41 timing arborist:ctor Completed in 0ms
    42 http fetch GET 200 https://registry.npmjs.org/eslint 950ms (cache revalidated)
    43 timing idealTree Completed in 1838ms
    44 timing command:install Completed in 1856ms
    45 verbose stack Error: could not resolve
    45 verbose stack     at PlaceDep.failPeerConflict (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibplace-dep.js:549:25)
    45 verbose stack     at PlaceDep.place (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibplace-dep.js:199:21)
    45 verbose stack     at new PlaceDep (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibplace-dep.js:73:10)
    45 verbose stack     at C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibarboristbuild-ideal-tree.js:990:31
    45 verbose stack     at Array.map (<anonymous>)
    45 verbose stack     at Arborist.[buildDepStep] (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibarboristbuild-ideal-tree.js:990:8)
    45 verbose stack     at async Arborist.buildIdealTree (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibarboristbuild-ideal-tree.js:218:7)
    45 verbose stack     at async Promise.all (index 1)
    45 verbose stack     at async Arborist.reify (C:Program Filesnodejsnode_modulesnpmnode_modules@npmcliarboristlibarboristreify.js:153:5)
    45 verbose stack     at async Install.exec (C:Program Filesnodejsnode_modulesnpmlibcommandsinstall.js:156:5)
    46 verbose cwd C:UsersjbocciDocumentsGitHubMendozaCiudadReactNativeApp
    47 verbose Windows_NT 10.0.18362
    48 verbose node v16.15.1
    49 verbose npm  v8.11.0
    50 error code ERESOLVE
    51 error ERESOLVE could not resolve
    52 error
    53 error While resolving: [1meslint-config-standard-react[22m@[1m11.0.1[22m
    53 error Found: [1meslint[22m@[1m8.18.0[22m[2m[22m
    53 error [2mnode_modules/eslint[22m
    53 error   [35mpeer[39m [1meslint[22m@"[1m>= 4.12.1[22m" from [1mbabel-eslint[22m@[1m10.1.0[22m[2m[22m
    53 error   [2mnode_modules/babel-eslint[22m
    53 error     [33mdev[39m [1mbabel-eslint[22m@"[1m^10.1.0[22m" from the root project
    53 error   [35mpeer[39m [1meslint[22m@"[1m^8.0.1[22m" from [1meslint-config-standard[22m@[1m17.0.0[22m[2m[22m
    53 error   [2mnode_modules/eslint-config-standard[22m
    53 error     [33mdev[39m [1meslint-config-standard[22m@"[1m^17.0.0[22m" from the root project
    53 error   10 more (eslint-config-standard-jsx, eslint-plugin-es, ...)
    53 error
    53 error Could not resolve dependency:
    53 error [35mpeer[39m [1meslint[22m@"[1m^7.12.1[22m" from [1meslint-config-standard-react[22m@[1m11.0.1[22m[2m[22m
    53 error [2mnode_modules/eslint-config-standard-react[22m
    53 error   [33mdev[39m [1meslint-config-standard-react[22m@"[1m^11.0.1[22m" from the root project
    53 error
    53 error Conflicting peer dependency: [1meslint[22m@[1m7.32.0[22m[2m[22m
    53 error [2mnode_modules/eslint[22m
    53 error   [35mpeer[39m [1meslint[22m@"[1m^7.12.1[22m" from [1meslint-config-standard-react[22m@[1m11.0.1[22m[2m[22m
    53 error   [2mnode_modules/eslint-config-standard-react[22m
    53 error     [33mdev[39m [1meslint-config-standard-react[22m@"[1m^11.0.1[22m" from the root project
    53 error
    53 error Fix the upstream dependency conflict, or retry
    53 error this command with --force, or --legacy-peer-deps
    53 error to accept an incorrect (and potentially broken) dependency resolution.
    53 error
    53 error See C:UsersjbocciAppDataLocalnpm-cacheeresolve-report.txt for a full report.
    54 verbose exit 1
    55 timing npm Completed in 2071ms
    56 verbose unfinished npm timer reify 1656683850227
    57 verbose unfinished npm timer reify:loadTrees 1656683850242
    58 verbose unfinished npm timer idealTree:buildDeps 1656683851083
    59 verbose unfinished npm timer idealTree:node_modules/eslint-config-standard-react 1656683851085
    60 verbose code 1
    61 error A complete log of this run can be found in:
    61 error     C:UsersjbocciAppDataLocalnpm-cache_logs2022-07-01T13_57_30_035Z-debug-0.log

If I run npm install whit --force or --legacy-peer-deps it remains the same, nothing changes.

If anyone knows how to resolve this please help. ^_^

Leave a Comment