Add fallback for devices without WebP support
In the latest nitter release, images in tweets do not display any more in some browsers, and as there’s no image size given in the element, there’s no placeholder shown either to realize that something's missing (and to click on it to open the file separately).
Example: https://nitter.net/pic/media%2Fsomething.jpg%3Fname%3Dsmall%26format%3Dwebp (The delivered file is in webp format.)
As the issue is not present in tweets that still deliver small images in png format (like from quoted tweets), it might be the webp format. There’s still quite a lot of devices and (unupdateable) browsers that do not support webp: https://caniuse.com/webp
Was there a change to display the small size images in webp rather than jpg and png? If yes, could you please consider reverting to jpg or png by default? Otherwise, nitter cannot be used by these browsers/devices and more. Thanks
(Escaping URL chars that appear in their special role might also not be the best idea, although it seems to work.)
This was done a while ago to significantly reduce bandwidth (more than 30%) used to proxy images. According to caniuse 96.76% of users support webp, with the main exceptions being Internet Explorer and versions of Safari more than 3 years old. For that reason I am not going to revert it, but I will look into supporting a fallback format.
Thanks. As nitter is a great alternative especially for lightweight clients and those that avoid the heavy J/S stuff at twitter.com, I assume that the caniuse statistics do not represent the actual nitter users. All Mozilla-based browsers before 2019 do not support webp as well, and many older browsers or devices cannot be updated.
The most simple and reliable server-side switch could be via HTTP accept header ( “image/webp” seems to be included in all major browsers now). https://developers.google.com/speed/webp/faq
Client-side, a , but this would only work with HTML5-capable browsers. https://caniuse.com/picture
... HTML5 (picture) element could be added around the (img), but this would fail with pre-HTML5 browsers. https://caniuse.com/picture
Is there a fallback option? Anything in options, or an instance that displays jpg/png and not webp on feed? It's sort of useless for me, sure I'm a luddite going against the tide, but a luddite I am, a luddite I will be, even upon death.
No, there's no option for this.
Will there ever be? It useless on my 32 bit windows 7 machine. No pull request to support fallbacks? Even my mac has trouble supporting webp in the programs I use for video and photo editing. Just wish there was a fallback.