ponnamkarthik / FlutterYoutube

Flutter Plugin to play youtube Videos
Apache License 2.0
126 stars 56 forks source link

This plugin puts the developer in violation of Youtube ToS on iOS #29

Open MagicalTux opened 5 years ago

MagicalTux commented 5 years ago

This plugin uses https://github.com/0xced/XCDYouTubeKit on iOS, which contains the following warning in its readme:

XCDYouTubeKit is against the YouTube Terms of Service. The only official way of playing a YouTube video inside an app is with a web view and the iframe player API. Unfortunately, this is very slow and quite ugly, so I wrote this player to give users a better viewing experience.

Because this plugin uses the official Youtube player module on android (com.google.android.youtube.player.YouTubePlayer) I had assumed something similar was the case on iOS, and used this plugin with this in mind, however about a week ago, playback broke for many videos (see issue https://github.com/0xced/XCDYouTubeKit/issues/419). Because it is not an officially supported player, this results in both terms of service violation and instability, risks, etc (when you have a live iOS app and it stops working, you can't just push a quick update - it needs to be approved by apple/etc).

While there isn't much that can be done about it, at least a warning should be shown in the README.

skjagini commented 5 years ago

Sorry for posting here. @MagicalTux thank you, I had the same opinion and I am using WebView to develop my app, any idea on how to handle Secure Origin with Flutter webview, https://stackoverflow.com/questions/54470420/flutter-web-view-secure-origin

MagicalTux commented 5 years ago

@skjagini why would you use html at all in this? Just remove use of Uri.dataFromString and set initialUrl to your embedding url directly (https://www.youtube.com/embed/vlkNcHDFnGA for example)