I am a passionate software developer attempting to learn in public.
I love learning and sharing and will be grateful for every opportunity to learn and improve.
@amabe_dev@mastodon.social
Note: It's not a great practice to rely on external images. You ideally want to have the fallback image locally in the file system, so it's a reliable fallback.
Definitely true. Otherwise we will enter an infinite loop because the onerror will be called again and again.
Also we probably want to display an better looking broken image placeholder for accessibility reasons. The fallback should show that this is not the intended image at first sight.
Definitely true. Otherwise we will enter an infinite loop because the onerror will be called again and again.
Also we probably want to display an better looking broken image placeholder for accessibility reasons. The fallback should show that this is not the intended image at first sight.
Exactly, trust me I tried it and it can crash Chrome 😂
Ah good second point, thanks for that 💖