루트 경로(/) 요청도 index.html처럼 캐시 안 되게 수정

firebase.json의 no-cache 규칙이 "/index.html" 경로에만 걸려있었는데,
실제로 브라우저는 "/"를 요청하고 SPA rewrite로 index.html을 받다보니
그 규칙이 안 먹혀서 1시간 동안 캐시됐다. 이 때문에 배포 직후에도
최대 1시간까지 이전 버전(스크롤 바운스 파란색 버그 등)이 그대로
보이는 문제가 있었음. "/" 경로에도 같은 no-cache 규칙을 추가.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-29 06:54:51 +00:00
co-authored by Claude Sonnet 5
parent bebbcb1d54
commit 10051e9896
+73 -1
View File
@@ -1 +1,73 @@
{"flutter":{"platforms":{"android":{"default":{"projectId":"school-display-ff28f","appId":"1:137322214849:android:2595999513206bdeb16b40","fileOutput":"android/app/google-services.json"}},"dart":{"lib/firebase_options.dart":{"projectId":"school-display-ff28f","configurations":{"android":"1:137322214849:android:2595999513206bdeb16b40","web":"1:137322214849:web:0423e5c788d95761b16b40"}}}}},"hosting":{"public":"build/web","ignore":["firebase.json","**/.*"],"rewrites":[{"source":"**","destination":"/index.html"}],"headers":[{"source":"/index.html","headers":[{"key":"Cache-Control","value":"no-cache, no-store, must-revalidate"}]},{"source":"/flutter_service_worker.js","headers":[{"key":"Cache-Control","value":"no-cache, no-store, must-revalidate"}]},{"source":"/version.json","headers":[{"key":"Cache-Control","value":"no-cache, no-store, must-revalidate"}]}]}} {
"flutter": {
"platforms": {
"android": {
"default": {
"projectId": "school-display-ff28f",
"appId": "1:137322214849:android:2595999513206bdeb16b40",
"fileOutput": "android/app/google-services.json"
}
},
"dart": {
"lib/firebase_options.dart": {
"projectId": "school-display-ff28f",
"configurations": {
"android": "1:137322214849:android:2595999513206bdeb16b40",
"web": "1:137322214849:web:0423e5c788d95761b16b40"
}
}
}
}
},
"hosting": {
"public": "build/web",
"ignore": [
"firebase.json",
"**/.*"
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
],
"headers": [
{
"source": "/index.html",
"headers": [
{
"key": "Cache-Control",
"value": "no-cache, no-store, must-revalidate"
}
]
},
{
"source": "/",
"headers": [
{
"key": "Cache-Control",
"value": "no-cache, no-store, must-revalidate"
}
]
},
{
"source": "/flutter_service_worker.js",
"headers": [
{
"key": "Cache-Control",
"value": "no-cache, no-store, must-revalidate"
}
]
},
{
"source": "/version.json",
"headers": [
{
"key": "Cache-Control",
"value": "no-cache, no-store, must-revalidate"
}
]
}
]
}
}