expo / react-native-action-sheet

A cross-platform ActionSheet for React Native
MIT License
1.4k stars 226 forks source link

Peer Dependency Issue #323

Closed NotTimTam closed 5 months ago

NotTimTam commented 6 months ago

This package is using an old version of react that conflicts with more up-to-date expo packages...

npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: hscitizensapp@2.1.7
npm ERR! Found: react@18.2.0
npm ERR! node_modules/react
npm ERR!   dev react@"^18.2.0" from the root project
npm ERR!   peer react@">=16.3.0" from @expo/react-native-action-sheet@4.0.1
npm ERR!   node_modules/@expo/react-native-action-sheet
npm ERR!     @expo/react-native-action-sheet@"^4.0.1" from the root project
npm ERR!   8 more (@react-navigation/drawer, @react-navigation/native, ...)
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! react-dom@"^18.2.0" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: react@18.3.1
npm ERR! node_modules/react
npm ERR!   peer react@"^18.3.1" from react-dom@18.3.1
npm ERR!   node_modules/react-dom
npm ERR!     react-dom@"^18.2.0" 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! 
NotTimTam commented 6 months ago

My Package.json

{
    "dependencies": {
        "@expo/react-native-action-sheet": "^4.0.1",
        "@react-navigation/drawer": "^6.6.15",
        "@react-navigation/native": "^6.1.17",
        "@react-navigation/native-stack": "^6.9.26",
        "axios": "^1.6.8",
        "chroma-js": "^2.4.2",
        "expo": "~51.0.6",
        "expo-file-system": "^17.0.1",
        "expo-secure-store": "^13.0.1",
        "expo-splash-screen": "^0.27.4",
        "expo-status-bar": "^1.12.1",
        "expo-system-ui": "^3.0.4",
        "flow.scss": "^1.0.7",
        "react-dom": "^18.2.0",
        "react-native": "^0.74.1",
        "react-native-circular-progress": "^1.4.0",
        "react-native-gesture-handler": "^2.16.2",
        "react-native-modal-selector": "^2.1.2",
        "react-native-reanimated": "^3.11.0",
        "react-native-safe-area-context": "^4.10.1",
        "react-native-sass-transformer": "^2.1.1",
        "react-native-screen": "^1.0.1",
        "react-native-svg": "^15.2.0",
        "react-native-web": "^0.19.11",
        "sass": "^1.77.1",
        "react": "^18.2.0",
    },
    "private": true,
    "devDependencies": {

        "@babel/core": "^7.24.5",
        "expo-dev-client": "^4.0.13"
    }
}
bradbyte commented 5 months ago

Fixed in 4.1.0.