당신이 잘 알고있는 경우 vue-router
구성은 매우 간단합니다.
첫째, @/router/index.js
당신이 추가 할 필요가 경로를 높일 수 있습니다.
예를 들면 : 엑셀이 페이지를 추가
{
path: '/excel',
component: Layout, redirect: '/excel/export-excel', name: 'excel', meta: { title: 'excel', icon: 'excel' } }
팁
영향을주지 않습니다 만,이 방법은, 그냥이에 따라 생성 layout
은 아래 경로, 당신이 필요로하는 children
하위 경로를 추가합니다.
{
path: '/excel',
component: Layout, redirect: '/excel/export-excel', name: 'excel', meta: { title: 'excel', icon: 'excel' }, children: [ { path: 'export-excel', component: ()=>import('excel/exportExcel'), name: 'exportExcel', meta: { title: 'exportExcel' } } ] }
에서와 같이 이러한 사이드가 나타납니다 menu-item
팁
때문에 children
오직 다음의 경로를 지정하는 경우 이들은 화살표를 확장해야하지 않을 children
수가 다음 경로가 아래와 같이 화살표를 확장 할 것이다 1보다 크다. 이 자동 판단이 사용할 수있는 무시하려면 alwaysShow: true
그 이전에 정의 된 규칙을 무시합니다 있도록 항상 루트 경로를 보여줍니다. 자세한 내용은 라우팅 및 기사를 참조하십시오
{
path: '/excel',
component: Layout, redirect: '/excel/export-excel', name: 'excel', meta: { title: 'excel', icon: 'excel' }, children: [ { path: 'export-excel', component: ()=>import('excel/exportExcel'), name: 'exportExcel', meta: { title: 'exportExcel' }}, { path: 'export-selected-excel', component: ()=>import('excel/selectExcel'), name: 'selectExcel', meta: { title: 'selectExcel' }}, { path: 'upload-excel', component: ()=>import('excel/uploadExcel'), name: 'uploadExcel', meta: { title: 'uploadExcel' }} ] }
같이 사이드가 나타납니다 submenu
http://www.vapsint.cn
http://www.moshii.cn
http://www.shamandaweiyu.cn
http://www.taiguangyinlou.cn
http://www.dexidunn.cn
에 http : // www가 .marbooo.cn
http://www.hiago.cn
http://www.fioan.cn
http://www.yumengse.cn
http://www.yajuxuan.cn
http://www.eternelle.cn