Closed birkanozekan closed 5 years ago
Hi! Did you install the library from npm? I just updated the readme; currently, you need to install directly from github.
My package.json file is like this;
"dependencies": { ... "react-native-google-cast": "https://github.com/flextv/react-native-google-cast/tarball/master",
My package.json file is like this;
"dependencies": { ... "react-native-google-cast": "https://github.com/flextv/react-native-google-cast/tarball/master",
@birkanozekan maybe it you should change to this.
"react-native-google-cast": "github:flextv/react-native-google-cast",
I don't think it's about package url. Files in my node_module/react-native-google-cast folder are up to date.
GoogleCast.getCastState() returns "NoDevicesAvailable" without error.
But GoogleCast.showIntroductoryOverlay() returns error "_reactNativeGoogleCast2.default.showIntroductoryOverlay is not a function"
When I deleted node_modules folder and re-install. Error about CastButton disappeared. But there's no button on screen. just an empty area with given width&height without touch event.
Tested with 7.0 and 8.0 android devices
My dependencies on build.gradle; compile project(':react-native-onesignal') compile project(':react-native-fetch-blob') compile project(':react-native-image-crop-picker') compile project(':react-native-orientation') compile project(':react-native-keep-awake') compile project(':react-native-video') compile project(':react-native-google-cast') compile fileTree(dir: "libs", include: ["*.jar"]) compile "com.android.support:appcompat-v7:25.1.0" compile "com.google.android.gms:play-services-cast:15.0.1" compile "com.android.support:mediarouter-v7:25.1.0" compile "com.facebook.react:react-native:+"
On Android, I've imported the library, without problem. import GoogleCast, { CastButton } from 'react-native-google-cast';
GoogleCast object works but when I add component in render section, I got this error; "Native Component for RNGoogleCastButton does not exist"
"react": "16.4.1", "react-native": "0.55.4",