Skip to content
This repository has been archived by the owner on Jun 30, 2022. It is now read-only.

Commit

Permalink
gotta set those cache controls
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronmgdr committed Mar 13, 2021
1 parent e3ca6b6 commit 7990a4e
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,21 @@ module.exports = {
},
],
},
{
source: '/api/holdings/:kind',
headers: [
{
key: "Cache-Control",
value: "public; max-age=30, stale-while-revalidate=360",
},
],
},
{
source: '/api/:any',
headers: [
{
key: "Cache-Control",
value: "public; max-age=10, stale-while-revalidate=20",
value: "public; max-age=5, stale-while-revalidate=20",
},
],
},
Expand Down

0 comments on commit 7990a4e

Please sign in to comment.