解决vue打包项目后刷新404的问题
来源:动视网
责编:小采
时间:2020-11-27 22:17:50
解决vue打包项目后刷新404的问题
解决vue打包项目后刷新404的问题:vue打包项目后刷新404的问题Nginx配置 server { listen 80; server_name localhost; index index.html; root /root/dist; location / { root /root/dist; try_files $uri $uri/ /index.html =404; }
导读解决vue打包项目后刷新404的问题:vue打包项目后刷新404的问题Nginx配置 server { listen 80; server_name localhost; index index.html; root /root/dist; location / { root /root/dist; try_files $uri $uri/ /index.html =404; }

vue打包项目后刷新404的问题Nginx配置
server {
listen 80;
server_name localhost;
index index.html;
root /root/dist;
location / {
root /root/dist;
try_files $uri $uri/ /index.html =404;
}
}
以上这篇解决vue打包项目后刷新404的问题就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持脚本之家。
解决vue打包项目后刷新404的问题
解决vue打包项目后刷新404的问题:vue打包项目后刷新404的问题Nginx配置 server { listen 80; server_name localhost; index index.html; root /root/dist; location / { root /root/dist; try_files $uri $uri/ /index.html =404; }