faizalshap / react-native-otp-verify

React native sms verification without additional permissions
MIT License
241 stars 95 forks source link

Error while installing the package in react version 0.66.3 #55

Closed LuciKritZ closed 2 years ago

LuciKritZ commented 2 years ago

Got an error while trying to install the package in react version 0.66.3. Full error log:

npm resolution error report

2022-03-27T17:43:16.252Z

While resolving: demo@1.0.0 Found: react-native@0.66.3 node_modules/react-native react-native@"0.66.3" from the root project

Could not resolve dependency: peer react-native@"^0.63.2" from react-native-otp-verify@1.0.4 node_modules/react-native-otp-verify react-native-otp-verify@"*" from the root project

Fix the upstream dependency conflict, or retry this command with --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution.

Raw JSON explanation object:


  "code": "ERESOLVE",
  "current": {
    "name": "react-native",
    "version": "0.66.3",
    "whileInstalling": {
      "name": "demo",
      "version": "1.0.0",
      "path": "/Users/krishal.shah/Documents/demo"
    },
    "location": "node_modules/react-native",
    "isWorkspace": false,
    "dependents": [
      {
        "type": "prod",
        "name": "react-native",
        "spec": "0.66.3",
        "from": {
          "location": "/Users/krishal.shah/Documents/demo"
        }
      }
    ]
  },
  "currentEdge": {
    "type": "prod",
    "name": "react-native",
    "spec": "0.66.3",
    "from": {
      "location": "/Users/krishal.shah/Documents/demo"
    }
  },
  "edge": {
    "type": "peer",
    "name": "react-native",
    "spec": "^0.63.2",
    "error": "INVALID",
    "from": {
      "name": "react-native-otp-verify",
      "version": "1.0.4",
      "whileInstalling": {
        "name": "demo",
        "version": "1.0.0",
        "path": "/Users/krishal.shah/Documents/demo"
      },
      "location": "node_modules/react-native-otp-verify",
      "isWorkspace": false,
      "dependents": [
        {
          "type": "prod",
          "name": "react-native-otp-verify",
          "spec": "*",
          "from": {
            "location": "/Users/krishal.shah/Documents/demo"
          }
        }
      ]
    }
  },
  "strictPeerDeps": false,
  "force": false
}
pushpender-singh-ap commented 2 years ago

Try to install (The latest version is still not published that why you facing this problem)

npm i react-native-otp-verify-remastered
Bilal-Abdeen commented 2 years ago

All of the following issues seem to be about the same problem - dependency on an old version of React-Native. PR#45 tried to fix the issue by updating the package.json file. However, I think package-lock.json needs to be updated as well.

41, #45 , #56 , #44, #50, #54, #55, #56.