Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

97
Views
Safari won't fallback an AVIF picture

I'm trying to render an image with the below code:

<picture>
  <source srcset="https://75tm.gr/GFXS1205/2048/GFXS1205.avif">
  <source srcset="https://75tm.gr/GFXS1205/2048/GFXS1205.webp">
  <img src="https://75tm.gr/GFXS1205/2048/GFXS1205.jpg">
</picture>

On Safari browsers, the image is not getting rendered at all. If I delete the first source though that has the .avif format, then Safari displays correctly the fallback .jpg image.

View on JsFiddle

Is this a Safari bug? If so, this really prevents the usage of the .avif format. Does anyone know of a workaround?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Safari can't fallback if you don't provide type attribute. So you need something like this (tested on Safari, works fine for me):

<picture>
  <source srcset="https://75tm.gr/GFXS1205/2048/GFXS1205.avif" type="image/avif">
  <source srcset="https://75tm.gr/GFXS1205/2048/GFXS1205.webp" type="image/webp">
  <img src="https://75tm.gr/GFXS1205/2048/GFXS1205.jpg">
</picture>

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!