Re:Show HN: Dotbun.com - A random bunny for your viewing ple...
by ibdf on Friday December 20, 2019 @08:05AM
(#21843841)
I have two buns, so I can appreciate this... but.. the website does not work in Safari. I am not a safari user, but when you share it on iphone Messages the default browser to open links is Safari.
[ Parent
| on HN ]
Re:Show HN: Dotbun.com - A random bunny for your viewing ple...
by Qub3d on Friday December 20, 2019 @08:45AM
(#21844047)
Unfortunately I don't have a good way to test on Safari. I'll see if I can find someone to help me with that.
Re:Show HN: Dotbun.com - A random bunny for your viewing ple...
by 0x14c1de72 on Friday December 20, 2019 @09:38AM
(#21844426)
The issue seems to be the webp format. I was also not seeing images on an old firefox version. You should use a picture element, so that you can provide working fallbacks.
Re:Show HN: Dotbun.com - A random bunny for your viewing ple...
by Qub3d on Friday December 20, 2019 @11:13AM
(#21845168)
Alright, I've gone ahead and replaced the css background-image with a <picture> element, with fallbacks:
<div class="imgbox center-fit">
<picture>
<source srcset="files/webp/file.webp" type="image/webp">
<source srcset="files/file.jpg" type="image/jpg">
<img src="files/file.jpg" alt="Bunny!">
</picture>
</div>
Let me know if that works.