From 5747eb75e65af1bb8d02de20da624e2a2b623182 Mon Sep 17 00:00:00 2001 From: Fuwn Date: Mon, 22 Jan 2024 21:25:30 -0800 Subject: feat(index.ts): Cache-Control --- index.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/index.ts b/index.ts index ae11e69..545f8e3 100644 --- a/index.ts +++ b/index.ts @@ -98,6 +98,11 @@ const handleRequest = async (originalRequest) => { // ); // } + response.headers.set( + "cache-control", + "public, immutable, s-maxage=31536000, max-age=31536000, stale-while-revalidate=60" + ); + return new Response(response.body, { status: response.status, statusText: response.statusText, -- cgit v1.2.3