router/index.js导出路由
let allRoutes = [{...aRouter},{...bRouter},{...cRouter},{...dRouter}]; export {allRoutes}使用:
//导入 import {allRoutes} from '@/router' //使用 let name=allRoutes[i].path.split("/")[1]
let allRoutes = [{...aRouter},{...bRouter},{...cRouter},{...dRouter}]; export {allRoutes}使用:
//导入 import {allRoutes} from '@/router' //使用 let name=allRoutes[i].path.split("/")[1]