-
-
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
Lighter Youtube Embeds #448
Comments
At a glance it looks like it just renders an image that loads the player properly on click. There's no reason you can't do this right now by just rendering a thumbnail that gets replaced with ReactPlayer after clicking. Some possible problems with including it as a feature of the library:
|
@cookpete All valid points. Some follow-up thoughts:
Totally, I figured it would be repeating logic for a lot of users. To fetch the thumbnail image, etc.
I think what I was realizing was that the benefits on page load and speed might be significant to recommend as a best practice for a popular library like this - standardizing an efficient soliution (even if it is opt-in). Thoughts? |
@cookpete Just following up if you had any more thoughts based on the above comment? |
Sorry @oyeanuj, all good points:
They do for me. Is it possible that these sites are over the new "media engagement" threshold on your Chrome, that allows autoplay? https://developers.google.com/web/updates/2017/09/autoplay-policy-changes#mei
Yeah fair point. We could have an
I guess as long as it is documented somewhere which players support thumbnail previews, then that's good enough. I think it's a good idea and wouldn't be too intrusive to implement. Happy to leave this issue open and look into it. |
@cookpete I was doing a little bit of research for something else and realized that Youtube and Vimeo both support thumbnail previews. Did you get a chance to look more into it as per your above comment? |
@cookpete Any updates on this one? Did you get a chance to look into it more? |
@oyeanuj |
@cookpete Thanks you! Just got a chance to implement it - it mostly worked great except for a couple of little things:
|
@cookpete Just wondering if you had any thoughts on the above issue? (1) is particularly a blocker on using this feature. |
Great, thank you for the quick fix! |
Fixes cookpete/react-player#558 Properly fixes cookpete/react-player#448
Fixes cookpete/react-player#558 Properly fixes cookpete/react-player#448
Fixes cookpete/react-player#558 Properly fixes cookpete/react-player#448
Fixes cookpete/react-player#558 Properly fixes cookpete/react-player#448
Hi @cookpete, back again!
One of the issues that I've been facing on my site is that even having a single Youtube embed on a page can really slow down the site. On researching further, it seems like Google+ and others use a slightly different technique for not loading Youtube videos by default, and instead only on click using the methods described below:
Thoughts on whether this library should support that?
The text was updated successfully, but these errors were encountered: