Skip to content

Commit a47f773

Browse files
committed
fix routes
1 parent af098e1 commit a47f773

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import React, { Component } from 'react';
2+
3+
export default class Wrapper extends Component {
4+
render() {
5+
return (
6+
<div>
7+
{this.props.children}
8+
</div>
9+
);
10+
}
11+
}

docs/client/routes.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,14 @@ import App from './components/App';
55
import NotFound from './components/NotFound';
66
import Home from './components/Home';
77
import About from './components/About';
8+
import Wrapper from './components/Wrapper';
89

910
export const routes = (
10-
<Route path="/" title="App" component={App}>
11+
<Route path="/" title="App" component={Wrapper}>
1112
<IndexRoute component={Home} />
12-
<Route path="about" title="App - About" component={About} />
13+
<Route path="/" title="App" component={App}>
14+
<Route path="about" title="App - About" component={About} />
15+
</Route>
1316
<Route path="*" title="404: Not Found" component={NotFound} />
1417
</Route>
1518
);

0 commit comments

Comments
 (0)