-
Notifications
You must be signed in to change notification settings - Fork 12
/
routes.js
61 lines (59 loc) · 1.41 KB
/
routes.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
const routes = [
{
path: "/",
component: () => import("layouts/MainLayout.vue"),
children: [
{ path: "", name: "Home", component: () => import("pages/Index.vue") },
{
path: "/register",
name: "Register",
component: () => import("pages/Register.vue")
},
{
path: "/login",
name: "Login",
component: () => import("pages/Login.vue")
},
{
path: "/verify",
name: "Verify",
component: () => import("pages/Verify.vue")
},
{
path: "/account",
name: "Account",
component: () => import("pages/Account.vue"),
meta: { requiresAuth: true }
},
{
path: "/forgot-password",
name: "ForgotPassword",
component: () => import("pages/ForgotPassword.vue")
},
{
path: "/reset-password",
name: "ResetPassword",
component: () => import("pages/ResetPassword.vue")
}
]
},
{
path: "/admin",
component: () => import("layouts/MainLayout.vue"),
children: [
{
path: "",
name: "AdminHome",
component: () => import("pages/admin/Index.vue"),
meta: { requiresAuth: true, requiresAdmin: true }
}
]
},
// Always leave this as last one,
// but you can also remove it
{
path: "*",
component: () => import("pages/Error404.vue")
}
];
export default routes;