diff --git a/panel/backend/app/main.py b/panel/backend/app/main.py index d02097c..475d740 100644 --- a/panel/backend/app/main.py +++ b/panel/backend/app/main.py @@ -88,8 +88,11 @@ @app.get("/{full_path:path}", include_in_schema=False) async def spa(full_path: str) -> FileResponse: - """Роуты Vue отдаём из dist, всё непонятное — index.html (SPA history).""" + """Роуты Vue отдаём из dist, всё непонятное — index.html (SPA history). + Без Cache-Control браузер эвристически кэширует index.html/лого — и после + деплоя продолжает жить в старом bundle: no-store защищает от этого.""" candidate = STATIC_DIR / full_path + headers = {"Cache-Control": "no-store"} if full_path and candidate.is_file(): - return FileResponse(candidate) - return FileResponse(STATIC_DIR / "index.html") \ No newline at end of file + return FileResponse(candidate, headers=headers) + return FileResponse(STATIC_DIR / "index.html", headers=headers) \ No newline at end of file