mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-27 07:52:24 +00:00
build(vercel): no-cache headers for HTML + service worker
Adds Cache-Control: no-cache,must-revalidate for the entry HTML (/ , *.html) and sw.min.js so Vercel-served domains (and any CDN/browser in front) always revalidate the shell and pick up new deploys, mirroring netlify.toml. Hashed JS/CSS keep far-future caching via their content-hashed filenames. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
1 parent
c79120ba04
commit
43c843dbae
1 file changed
+21
-1
+21
-1
@@ -1,5 +1,25 @@
|
||||
{
|
||||
"buildCommand": "npm run build",
|
||||
"outputDirectory": "dist",
|
||||
"installCommand": "npm install"
|
||||
"installCommand": "npm install",
|
||||
"headers": [
|
||||
{
|
||||
"source": "/sw.min.js",
|
||||
"headers": [
|
||||
{ "key": "Cache-Control", "value": "no-cache, must-revalidate" }
|
||||
]
|
||||
},
|
||||
{
|
||||
"source": "/",
|
||||
"headers": [
|
||||
{ "key": "Cache-Control", "value": "no-cache, must-revalidate" }
|
||||
]
|
||||
},
|
||||
{
|
||||
"source": "/(.*\\.html)",
|
||||
"headers": [
|
||||
{ "key": "Cache-Control", "value": "no-cache, must-revalidate" }
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in new issue
Block a user