Skip to content

Commit

Permalink
fix: 更新守卫文档
Browse files Browse the repository at this point in the history
  • Loading branch information
Gcaufy committed Oct 4, 2020
1 parent 749a1b8 commit 4d156e8
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 9 deletions.
14 changes: 9 additions & 5 deletions packages/router/README.md
@@ -1,6 +1,10 @@
* [Usage](/router/usage.md)
* [配置](/router/config.md)
* [导航守卫](/router/guard.md)

**Coming soon**


* [Usage](./doc/usage.md)
* [配置](./doc/config.md)
* [导航守卫](./doc/guard.md)
* API
* [router](/router/router.md)
* [实例](/router/instance.md)
* [router](./doc/router.md)
* [实例](./doc/instance.md)
12 changes: 9 additions & 3 deletions packages/router/doc/config.md
Expand Up @@ -10,9 +10,15 @@ tabPages = ['CourseList']
routeMap = {
SplashScreen: '/pages/SplashScreen',
CourseList: '/pages/tabBar/courseList/CourseList',
ClassList: { name: 'CourseList', query: { courseType: 'class' } },
BookList: { path: '/pages/BookList', query: { info: { name: 'roma' } }, meta: 2},
CityList: { handler: ({ query }) => ({ path: '/pages/CityList', query }) },
ClassList: {
name: 'CourseList', query: { courseType: 'class' }
},
BookList: {
path: '/pages/BookList', query: { info: { name: 'roma' } }, meta: 2
},
CityList: {
handler: ({ query }) => ({ path: '/pages/CityList', query })
},
Courses: 'CourseList'
}
```
Expand Down
5 changes: 4 additions & 1 deletion packages/router/doc/usage.md
Expand Up @@ -18,7 +18,10 @@ const routeMap = {
SplashScreen: '/pages/SplashScreen',
CourseList: '/pages/tabBar/courseList/CourseList',
CourseDetail: '/pages/CourseDetail','
CourseOnlineDetail: { name: 'CourseDetail', query: { courseType: 'online' } },
CourseOnlineDetail: {
name: 'CourseDetail',
query: { courseType: 'online' }
},
}
const config = { homePage, tabPages, routeMap }
Expand Down

0 comments on commit 4d156e8

Please sign in to comment.