UNPKG

fe-core-cli

Version:

All-in-one scaffolding, cli integrated with Vue3 ecological chain, cli of H5 page, mock template cli of Node

31 lines (28 loc) 710 B
import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router'; const routes: Array<RouteRecordRaw> = [ { path: '/login', name: 'Login', meta: { title: '登录', keepAlive: true, requireAuth: false, }, component: () => import('@/pages/login.vue'), }, { path: '/', name: 'Index', meta: { title: '首页', keepAlive: true, requireAuth: true, }, component: () => import('@/pages/index.vue'), }, ]; const router = createRouter({ history: createWebHistory(), routes, }); export default router;