2019-06-03 13:06:44 +02:00
|
|
|
import Vue from 'vue'
|
|
|
|
import VueRouter from 'vue-router'
|
|
|
|
|
|
|
|
import Home from 'vuejs/components/Content/Home'
|
|
|
|
import Base from 'vuejs/components/Content/Base'
|
|
|
|
|
|
|
|
Vue.use(VueRouter)
|
|
|
|
|
2019-06-04 22:38:44 +02:00
|
|
|
// https://www.lullabot.com/articles/decoupled-hard-problems-routing
|
|
|
|
|
2019-06-03 13:06:44 +02:00
|
|
|
export default new VueRouter({
|
2019-06-04 22:38:44 +02:00
|
|
|
mode: 'history',
|
2019-06-03 13:06:44 +02:00
|
|
|
routes: [
|
|
|
|
{
|
|
|
|
path: '/',
|
|
|
|
name: 'home',
|
|
|
|
components: {
|
|
|
|
'home': Home
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/base',
|
|
|
|
name:'base',
|
|
|
|
components: {
|
|
|
|
'base': Base
|
|
|
|
}
|
|
|
|
},
|
2019-06-04 22:38:44 +02:00
|
|
|
// {
|
|
|
|
// path: '*',
|
|
|
|
// name: 'notfound',
|
|
|
|
// components: {
|
|
|
|
// 'notfound': NotFound
|
|
|
|
// }
|
|
|
|
// }
|
2019-06-03 13:06:44 +02:00
|
|
|
]
|
|
|
|
})
|