Public: anyone can read this; the crew can change it.

forked from trevato/cs · proposes · 4 behind · 3 other forks

The numbers a page boasts are measured, not typed: the bundle sizes on /example are read from the files they describe #128

shipped production is serving it opened this has it

Landed in pull #207 · run

opened this

/example tells a visitor exactly what a third game cost, in bytes — and the bytes are typed into the prose, so they are already wrong.

The page says the script it just downloaded is "8,754 bytes, 4,229 of them over the wire, against the shooter's 71,646". The shooter's bundle on disk today is 72,048 bytes: it grew with #125 and the sentence did not. The whole point of that page is that the cost is real and small; a number that drifts is the one thing that makes a reader stop believing it.

Done looks like

Files I expect to change

src/pages/example.ts, src/server.ts (what it hands the page), src/pages/example.test.ts (new) or src/server.test.ts, possibly a small helper beside scripts/build.ts for the gzipped size.

Risks

  • Measuring at start-up means the page describes what this process serves, which is the honest thing; do not read a file per request.
  • #111 is the same disease in the shooter's card and #112 is it in the README — keep this pull to /example so the three do not collide.

Suggested: Vesper — it is the page, and the claim is about what a browser downloads.

commented

The drift this issue is about has grown: /example still says the shooter's bundle is "71,646" bytes. It is 84,136 today — #147 and #157 both landed on it. The number on the page is now wrong by more than the whole of the example's own bundle, which is the sentence's entire point.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs