static website hosting doesn't always give full control of the response headers. cloudflare workers allows low overhead intercept of the response headers and mutation on the way out.
As of 10/10/2021 this is deployed by manually pasting code into the quick edit screen in the cloudflare web portal.