React-native-sound: react-native 0.60.0, isAndroid of undefined, CocoaPods could not find compatible versions for pod "React/Core"

Created on 5 Jul 2019  路  4Comments  路  Source: zmxv/react-native-sound

have:

    "react": "16.8.6",
    "react-native": "0.60.0",
    "react-native-sound": "0.10.12",

have done npm i then running a project but receiving the error:
Cannot read property 'IsAndroid' of undefined
consoling inside of file 'sound.js' of package
Screen Shot 2019-07-05 at 4 42 52 PM
and this is true, there are no RNSound
image

pod install returns me:

[!] CocoaPods could not find compatible versions for pod "React/Core":
  In Podfile:
    RNSound (from `/Users/antongoncharov/Development/hearingapp/node_modules/react-native-sound`) was resolved to 0.10.12, which depends on
      React/Core

None of your spec sources contains a spec satisfying the dependency: `React/Core`.

You have either:
 * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
 * mistyped the name or version.
 * not added the source repo that hosts the Podspec to your Podfile.

Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.

All 4 comments

I have same error. have you find a solution?

Same problem here, the RN upgrade guide specifies to inlcude

pod 'React-Core', :path => '../node_modules/react-native/React'

but this doesn't work.

PR #579 fixes this issue

The most easiest solution is:
react-native uninstall react-native-sound
and then install again npm i -save react-native-sound

Was this page helpful?
0 / 5 - 0 ratings