8

I wonder if it is at all possible to play Vimeo and YouTube via the React Native component react-native-video. My research so far points to this being virtually impossible, because react-native-video needs a direct reference to a file (or a stream?) and these references are hard/difficult to obtain for YouTube and Vimeo?

Is there any way to get react-native-video working with Vimeo & YouTube?

Hendrik
  • 1,505
  • 3
  • 15
  • 20

2 Answers2

7

react-native-video will work with Vimeo, if you subscribe to Vimeo Pro.

Vimeo Pro offers the ability to use your video own third party player, which lets you get the url for your video in 360p, 540p, 720p, or 1080p specifically or as an HTTP Live Streaming url which can choose the correct resolution/bitrate for the user's connection. react-native-video work with any of these formats!

greg5green
  • 400
  • 1
  • 7
3

I know a github project which is a Youtube component for react-native. Check it out, maybe it can help you ;)

Here you have an other project for Vimeo videos

LuisPinto
  • 1,667
  • 1
  • 17
  • 36
  • 1
    Thanks for the input, but these two have their own drawbacks: The YouTube component lacks Android support. The Vimeo component has WebViewNativeBridge as a dependency which has issues of its own – Hendrik Sep 02 '16 at 15:12
  • Hi @Hendrik right now, react-native-youtube works in Android if the device has Youtube installed, and react-native-vimeo don't uses WebViewNativeBridge anymore, just the standard WebView. I would recommend using react-native-youtube but not react-native-vimeo, instead take the idea and create your own hosted page to render those videos. Anyway, react-native-vimeo still don't work on Android. – MrBrownser Dec 13 '17 at 11:07