Skip to content

Scheduling infrastructure for absolutely everyone.

fix: caching for sprite.svg (#20832)

Vijayf5217caef20e
diff --git a/apps/web/next.config.js b/apps/web/next.config.js
index 8dc35c8d1d4..08adfa9c2e3 100644
--- a/apps/web/next.config.js
+++ b/apps/web/next.config.js
@@ -498,8 +498,15 @@ const nextConfig = {
headers: [CORP_CROSS_ORIGIN_HEADER],
},
{
- source: "/icons/sprite.svg",
- headers: [CORP_CROSS_ORIGIN_HEADER, ACCESS_CONTROL_ALLOW_ORIGIN_HEADER],
+ source: "/icons/sprite.svg(\\?v=[0-9a-zA-Z\\-\\.]+)?",
+ headers: [
+ CORP_CROSS_ORIGIN_HEADER,
+ ACCESS_CONTROL_ALLOW_ORIGIN_HEADER,
+ {
+ key: "Cache-Control",
+ value: "public, max-age=31536000, immutable",
+ },
+ ],
},
],
...(isOrganizationsEnabled