解决vue项目发布客户端缓存html导致js请求404故障

nginx配置/及.html结尾的请求,响应头添加Cache-Control no-store

location / {
            if ($request_uri ~* '/$|\.html$') {
                  add_header Cache-Control no-store;
            }
            root  html;
            index index.html;
        }
发布了169 篇原创文章 · 获赞 43 · 访问量 38万+

猜你喜欢

转载自blog.csdn.net/hknaruto/article/details/104968131