Support Youtube thumbnail URLs
Is there a way we can have it so this module supports Youtube thumbnail URLs? Here is a relevant Stackoverflow question.
Ideally the regex would support URLs such as
https://img.youtube.com/vi/<insert-youtube-video-id-here>/default.jpg
https://img.youtube.com/vi/<insert-youtube-video-id-here>/hqdefault.jpg
Along with the other quality thumbnails.
Hi and thanks for this issue. I will review it in the weekend or sooner
@augbog hm, or it's pretty easy http://regexr.com/3bdh0 like this?
haha, it's going to be more and more better than ever and than every other implementation!
^ Nope, exactly, :cat2:
// thumbnails
img.youtube.com/vi/0EWbonj7f18/default.jpg
i.ytimg.com/vi_webp/WijF8aivOo8/mqdefault.webp
i1.ytimg.com/vi/G0wGs3useV8/0.jpg
img.youtube.com/vi/G0wGs3useV8/3.jpg
that are with number like /3.jpg works, but not the others like /default.jpg, so yea... I can continue in weekend.
Yup that looks about right. I'm not sure what exactly the different urls are (all the ones listed in the Stackoverflow question are ones I go off of) and it seems to work fine. The regex you use for the youtube video id should be the same though in the middle part of the url.
Here's more info on Video thumbnails if it helps!
/cc @regexps/owners thoughts? this change (?:ytimg|youtube) seems to fixes the issue partially what more?