vue 项目部署后 刷新一下 页面找不到 解决

1.修改配置router的参数:

2.

后端配置例子

Apache

<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteRule ^index\.html$ - [L]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule . /index.html [L]
</IfModule>

  

猜你喜欢

转载自www.cnblogs.com/tongbiao/p/9384034.html