Skip to content

Commit

Permalink
added 30 minute cache as default
Browse files Browse the repository at this point in the history
  • Loading branch information
Cmoen11 committed Sep 30, 2024
1 parent 2931b13 commit 340aec5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions apps/docs/app/entry.server.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,10 @@ export default function handleRequest(
</ServerStyleContext.Provider>,
);

const cacheControl = "public, max-age=1800"; // 30 minute cache

responseHeaders.set("Content-Type", "text/html");
responseHeaders.set("Cache-Control", cacheControl);

return new Response(`<!DOCTYPE html>${markup}`, {
status: responseStatusCode,
Expand Down

0 comments on commit 340aec5

Please sign in to comment.