Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Commit

Permalink
Reset the scroll-position to the page-top when changing pages.
Browse files Browse the repository at this point in the history
  • Loading branch information
mammuth committed Apr 10, 2016
1 parent 007931d commit 15fb07f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/main.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ browserHistory.listen(location => {
});

ReactDOM.render(
<Router history={browserHistory}>
<Router onUpdate={() => window.scrollTo(0, 0)} history={browserHistory}>
<Route path="/" component={App}>
<IndexRoute component={Start}/>
<Route path="/ranking" component={Ranking}/>
Expand Down

0 comments on commit 15fb07f

Please sign in to comment.