37 lines
716 B
TypeScript
37 lines
716 B
TypeScript
import Vue from 'vue'
|
|
import VueRouter, { RouteConfig } from 'vue-router'
|
|
import pageNoFoundComponent from 'common/notFound'
|
|
import indexComponent from 'common/index'
|
|
import OverviewComponent from '@/views/overview.component'
|
|
import PopupComponent from "@/popup/pop.component.vue"
|
|
|
|
Vue.use(VueRouter)
|
|
const routes: Array<RouteConfig> = [
|
|
|
|
{
|
|
path: '/',
|
|
name: 'index',
|
|
redirect:"/home",
|
|
},
|
|
{
|
|
path: '/home',
|
|
name: 'indexComponent',
|
|
component:OverviewComponent
|
|
},
|
|
{
|
|
path: '/popup',
|
|
name: 'popup',
|
|
component: PopupComponent
|
|
},
|
|
{
|
|
path: '*',
|
|
name: '404',
|
|
component: pageNoFoundComponent
|
|
},
|
|
]
|
|
|
|
const router = new VueRouter({
|
|
routes,
|
|
})
|
|
export default router
|