4
0
mirror of https://github.com/iczer/vue-antd-admin.git synced 2025-05-21 13:39:18 +08:00
iczer f5b452f82b feat: add support for async router; 🌟
新增:添加异步路由支持;
2020-07-26 22:08:31 +08:00

25 lines
430 B
JavaScript

import Mock from 'mockjs'
Mock.mock('/routes', 'get', () => {
let result = {}
result.code = 0
result.data = [{
router: 'root',
children: ['demo',
{
router: 'parent1',
children: ['demo'],
},
{
router: 'parent2',
children: ['demo'],
},
{
router: 'exception',
children: ['exp404', 'exp403', 'exp500'],
}
]
}]
return result
})