chanmin0723 Claude Opus 4.8 commited on
Commit
a6bb2b8
·
1 Parent(s): e32b28f

[fix] index no-cache header to prevent stale cached page

Browse files

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

Files changed (1) hide show
  1. app/main.py +5 -1
app/main.py CHANGED
@@ -250,4 +250,8 @@ if FRONTEND_DIR.exists():
250
 
251
  @app.get("/")
252
  def index() -> FileResponse:
253
- return FileResponse(str(FRONTEND_DIR / "index.html"))
 
 
 
 
 
250
 
251
  @app.get("/")
252
  def index() -> FileResponse:
253
+ # no-cache: 브라우저가 매번 재검증하도록 강제 (구버전 HTML/JS 캐시로 인한 표시 누락 방지)
254
+ return FileResponse(
255
+ str(FRONTEND_DIR / "index.html"),
256
+ headers={"Cache-Control": "no-cache, max-age=0, must-revalidate"},
257
+ )