vue项目中每一个url都有一个"#/", 在路由的index.js 中使用history模式去掉了这个"#/",但是打包之后就访问不到index.html中的内容了, 这是怎么回事呢? 望各位大佬解答一下.
收起
vue项目vue-router路由history模式打包后放在服务器上要在WEB-INF/web.xml文件中配置:
<error-page> <location>/index.html</location> <error-code>404</error-code> </error-page>
同时项目中也要一个404页面:
报告相同问题?