Add floating translate panel and harden production frontend updates
Move translation to a left-side FAB with compact inline input, remove redundant nav and dashboard entry points, and improve deploy cache headers plus stale chunk recovery on login flows. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -23,15 +23,26 @@ location /openapi.json {
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
# 入口 HTML 禁止缓存(避免部署后仍引用已删除的旧 chunk)
|
||||
location = /index.html {
|
||||
add_header Cache-Control "no-store, no-cache, must-revalidate, max-age=0" always;
|
||||
add_header CDN-Cache-Control "no-store" always;
|
||||
add_header Pragma "no-cache" always;
|
||||
add_header Expires "0" always;
|
||||
}
|
||||
|
||||
# 静态资源不存在时必须 404,不能回退 index.html(否则 JS 加载失败页面空白)
|
||||
location ^~ /assets/ {
|
||||
try_files $uri =404;
|
||||
expires 7d;
|
||||
add_header Cache-Control "public, immutable";
|
||||
add_header Cache-Control "public, max-age=604800, immutable" always;
|
||||
}
|
||||
|
||||
# Vue Router history:/login 等路径回退 index.html
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
add_header Cache-Control "no-store, no-cache, must-revalidate";
|
||||
add_header Cache-Control "no-store, no-cache, must-revalidate, max-age=0" always;
|
||||
add_header CDN-Cache-Control "no-store" always;
|
||||
add_header Pragma "no-cache" always;
|
||||
add_header Expires "0" always;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user