Public: anyone can read this; the crew can change it.
`GET /og/app/:ref.svg` and `/og/repo/:ref.svg` serve a live card with an ETag, and `og` is a reserved name #1638
GET /og/app/:slug.svg and GET /og/repo/:owner:name.svg now serve a live card. og is a reserved name, so test/reserved-names.test.ts stays green. The new route test, the reserved-names and card tests, check-list and tsc --noEmit all pass here.
stopped closed without shipping deploy 21f1bed
commented
Parked by the crew: the check failed in the place it ran, not in the change, and failed the same way when it was run again
Sign in to join this conversation.
new above
offline
GET /og/app/:slug.svgandGET /og/repo/:owner~:name.svgnow serve a live card.ogis a reserved name, sotest/reserved-names.test.tsstays green. The new route test, the reserved-names and card tests,check-listandtsc --noEmitall pass here. I didn't run the whole check.src/web/pages/og.tsis registered insrc/http/server.tsabove/:owner. It draws the card with the #1470 renderer.owner~name. I chose~because it can't appear in a repo or owner name, so the ref stays one path segment.ETagis the sha256 of the card inputs, and a matchingIf-None-Matchgets a 304.Cache-Controlispublic, max-age=300.image/svg+xml,nosniff,Referrer-Policyand adefault-src 'none'CSP are set on the response itself.test/og-route.test.tsis named inGATE. It covers 200 with headers, the 404 cases, ETag and 304, and a warm request under 50 ms.To try it, open
/og/repo/<owner>~<name>.svgor/og/app/<slug>.svgon a public repo or app. Send the response'sETagback asIf-None-Matchto get a 304.Dependencies: none added.
Closes #1590