yapi/client/routes.js

24 lines
803 B
JavaScript
Raw Normal View History

2017-07-05 14:10:06 +08:00
import React from 'react'
2017-07-11 10:27:56 +08:00
import { Route, HashRouter } from 'react-router-dom'
2017-07-18 12:53:53 +08:00
import { Header, Home, ProjectGroups, Interface, News, AddInterface } from './containers/index'
2017-07-17 11:01:05 +08:00
import User from './containers/User/User.js'
2017-07-10 20:28:03 +08:00
export default () => {
2017-07-05 14:10:06 +08:00
return (
2017-07-09 21:47:19 +08:00
<HashRouter>
2017-07-07 17:26:31 +08:00
<div className="router-main">
<Header/>
2017-07-14 14:44:32 +08:00
<Route path="/" component={ Home } exact />
2017-07-28 17:30:56 +08:00
2017-07-25 15:53:55 +08:00
<Route path="/group" component={ ProjectGroups } >
<Route exact={false} path="/group/:groupName" component={ ProjectGroups } />
</Route>
2017-07-28 17:30:56 +08:00
<Route path="/project" component={ Interface } />
2017-07-17 19:27:20 +08:00
<Route path="/user" component={User} />
2017-07-17 12:24:06 +08:00
<Route path="/News" component={ News } />
2017-07-28 17:30:56 +08:00
<Route path="/add-interface" component={ AddInterface } />
2017-07-07 17:26:31 +08:00
</div>
2017-07-09 21:47:19 +08:00
</HashRouter>
2017-07-05 14:10:06 +08:00
)
2017-07-10 20:26:49 +08:00
}