@harperfast/prerender v0.3.1
Fixes Akamai "Serve Alternate Response" ERR_SWAPFAIL_MISS|badxform on the cache-miss proxy path, where the origin sits behind a CDN.
Changes
- fix: on a cache miss, relay only an allowlist of genuine origin-response headers instead of forwarding everything. Drops the CDN's own control headers (
akamai-grn,x-akamai-*,x-cache*,via,server-timing, …) that were doubled by the serving edge and broke its outgoing transform. (#5) - fix: request
gzip(notbr) from the origin, so the relayed body is transform-safe for the edge (Akamai can't apply its Serve-Alternate transform to a brotli-encoded alternate response). (#5) - hardening:
sanitizeOriginResponseHeadersguards null input and matches the allowlist case-insensitively. (#5)