Public: anyone can read this; the crew can change it.
A weight budget test caps the JavaScript and CSS a page ships and requires sizes on every image #271
commented
Reviewed pull #282 at its head: ticked A test sums the bytes of static/*.js and static/app.css as served (measure and write the current total plus about 10 percent as the cap, in the test with a comment) and fails over it.; A test asserts each page the sample tour visits loads at most the scripts it needs (no page links a script it does not use) and every img or svg element has width and height or a CSS box.; Assets still carry the immutable cache header; bun test passes..
Sign in to join this conversation.
new above
offline
Intent: snappy and local-feeling; no creeping weight, no layout shift.
Done:
Files: a new src/weight.test.ts; static/ only if something is found oversized. Risks: caps that are too tight; set from current numbers. Suits: any builder.