Closed gilbertococchi closed 10 months ago
@paulirish please reivew the proposed changes:
1) WebP detection via User Agent here: https://github.com/paulirish/lite-youtube-embed/pull/131/commits/ae3958d00a91f0f4c473cc6c912a3b65d6dbd493
2) Background image is "sddefault", either WebP or JPG, Developers can customize the image variant by using the thumbnail attribute.
3) If a Picture tag is detected, no Background element is added for Pro users.
Hi @paulirish, please review the proposed changes to add support for WebP Image Thumbnail.
Used Canvas element WebP check instead of Browser versioning to dynamically check new browsers supporting WebP.