diff --git a/next.config.js b/next.config.js index f40087c..f483edd 100644 --- a/next.config.js +++ b/next.config.js @@ -7,4 +7,44 @@ module.exports = withPlausibleProxy({ images: { unoptimized: true, }, + async headers() { + return [ + { + source: '/bookmarks/(.+)', + headers: [ + { + key: 'Cache-Control', + value: 's-maxage=2592000, stale-while-revalidate=86400', + }, + ], + }, + { + source: '/collection/(.+)', + headers: [ + { + key: 'Cache-Control', + value: 's-maxage=2592000, stale-while-revalidate=86400', + }, + ], + }, + { + source: '/home/(.+)', + headers: [ + { + key: 'Cache-Control', + value: 's-maxage=2592000, stale-while-revalidate=86400', + }, + ], + }, + { + source: '/profile/(.+)', + headers: [ + { + key: 'Cache-Control', + value: 's-maxage=2592000, stale-while-revalidate=86400', + }, + ], + }, + ]; + }, });