mda100 / noel-website

photo album for noel
0 stars 0 forks source link

image loading optimization #22

Closed mda100 closed 1 year ago

mda100 commented 1 year ago

images load slowly: https://developer.mozilla.org/en-US/docs/Learn/Performance/Multimedia

  1. lazy loading https://github.com/aFarkas/lazysizes
  2. optimal sizing - convert all images to same size at build / consider two different sizes for mobile and web
  3. optimal format - convert all images to webp, webm, or compressed jpeg at build
  4. downloading priority - download images in order of when they will be displayed on the carousel
  5. define dimensions in img tag to prevent jank loading

seems like the central ideas are

  1. script that creates optimal images
  2. load images in progressively according to priority
  3. define image sizes ahead of time
mda100 commented 1 year ago
  1. lazy load / priority downloading
  2. webp / progressive jpeg
  3. optimal size / jank / responsive sizing
  4. video https://developer.mozilla.org/en-US/docs/Learn/Performance/video
  5. possibly CDN
mda100 commented 1 year ago
mda100 commented 1 year ago

if we have continue speed problems:

mda100 commented 1 year ago

closed by #38 and #45 and #46