import Vue from "vue";
import Router from "vue-router";

Vue.use(Router);


export default new Router({
    mode: "history",
    routes: [
        {
            path: "/login",
            component: () => import("@/view/pages/Login"),
        },
        {
            path: "/",
            redirect: "/dashboard",
            component: () => import("@/view/layout/Base"),
            children: [
            {
                path: "/dashboard",
                name: "dashboard",
                component: () => import("@/view/pages/Dashboard.vue")
            },
            {
                path: "/Community",
                name: "Community",
                component: () => import("@/view/pages/Community.vue")
            },
            {
                path: "/materials",
                name: "Materials",
                component: () => import("@/view/pages/Materials.vue")
            },
            {
                path: "/analytics",
                name: "Analytics",
                component: () => import("@/view/pages/Analytics.vue")
            },
            ]
        }
    ]
});