fix(router): Back on history mode because 👌

This commit is contained in:
Tixie 2019-04-07 02:47:14 +02:00
parent 03d40b8cb1
commit 69ccbc780d
2 changed files with 11 additions and 2 deletions

8
public/.htaccess Normal file
View file

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

View file

@ -9,11 +9,12 @@ import Download from '/views/screens/download'
Vue.use(VueRouter)
export default new VueRouter({
mode: 'hash',
mode: 'history',
routes: [
{ name: 'home', path: '/', component: Welcome },
{ name: 'capture', path: '/capture', component: Capture },
{ name: 'preview', path: '/preview', component: Preview },
{ name: 'download', path: '/download', component: Download }
{ name: 'download', path: '/download', component: Download },
{ path: '*', redirect: { name: 'home' } }
]
})