在Nginx中配置try_files
server {
listen 80;
server_name localhost;
root "****";
location / {
try_files $uri $uri/ /index.html;
index index.php index.html;
error_page 404 /error/404.html;
include ***;
autoindex off;
}
location /api/ {
proxy_pass http://localhost:8055;
}
}
标签:index,Vue,cli,app,error,404,html,跳转
From: https://www.cnblogs.com/wz0130/p/16905524.html