-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
YouTube videos won't play in IE #39
Comments
I'm not sure whether the best thing to do is to force a certain polyfill upon people, or just advise that you will need a polyfill for promises in your projects if you would like to support older browsers (much like the fetch polyfill does), although IE11 isn't exactly old.. Happy for suggestions on this. |
As it is now, ReactPlayer has no support for IE, at least for YouTube videos. I think you should put it in the readme if you don't want to force polyfills on people. As a user of ReactPlayer, I wouldn't mind installing an optional polyfill, but I'd like to know about it in advance. ReactPlayer is one of multiple React-based video players, and when I did reasearch for which one to choose, I based my decision on the readme file of each project. The more information you can give in the readme, the easier it will be for others to chose one or the other. I'd write something like:
I would recommend only polyfills that wouldn't require me to do any coding, if there are any that does. I haven't checked them all. A little bit off topic, but since we are talking about the readme file. I'd like to put in a suggestion for adding a reminder that mobile browsers don't support autoplay. This is important because it can affect how we implement the video in the website. I have recently finished a website project where we put up a video behind a splash image. You click the image, it gets replaced with a video that starts playing automatically. This doesn't work on mobile. YouTube throws an error after some time of preloading. It looks like something is wrong. We added a simple check for the user agent string (I know, I know...) to disable autoplay for mobile browser. It adds a second step (click the splash image, then click the YouTube play button) which wasn't what we wanted. I had completely forgot about that issue until it became one. Good work on the component! It works much better than the others. :-) |
Thanks for the comments @mandarinx. I've had a further look at this and actually packaging with polyfills is cleaner and less problematic than I first thought. It also fixes the confusion of specifically polyfilling webpack, but not the final compiled builds. See 6478630, which will be part of the next release and hopefully fix ReactPlayer for latest IE versions. |
I've just added a quick explanation of this to the readme. |
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
Previously we were polyfilling using webpack, which of course only affected the demo and not the actual build Fixes cookpete/react-player#39
IE complains about missing Promise.
I fixed it in a local install (because my deadline is in a few minutes) by installing [https://github.com/stefanpenner/es6-promise] and importing in the YouTube player. That fixed it for both IE 10 and 11.
I'd be happy to make a pull request, if you'd like.
The text was updated successfully, but these errors were encountered: