Optimize images on CDN

Aperta
#720 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
30/100
Tipo di issue
Refactoring
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Ambito
cloud, performance

Direzione di ricerca

The payload names no files or code paths, so start by finding where the sprite and backdrop image URLs are referenced in the scratch-editor repo and what they point to on the CDN. The open question is how the CDN is updated, so confirm that process with the maintainers before generating assets. Done means optimized files are in place on the CDN and the loading code uses them, with the size reduction measured.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

The sprite and backdrop images on the CDN are not optimized for the web.
Choosing the correct image type jpg vs. png can make a huge difference. Also pasting the svgs through svgomg gives 20%+ reduction in file size.

I can generate the optimized images and change the code for the loading part. How can the images updated in the CDN?

Whay this?
Reduction of bandwidth - saves CO2 and makes the page quicker.
I also created issue https://github.com/scratchfoundation/scratch-editor/issues/719 for optimizing the loading with loading="lazy" tag.

Lingua principale
JavaScript
Stelle
310
Fork
299
Merge medio
19h 41m
PR unite (30g)
14

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di scratchfoundation/scratch-editor

Tutte le issue di scratchfoundation/scratch-editor

Issue simili

Altre issue su JavaScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.