Browse Source

fix enter-animation router demo

pull/297/head
afc163 9 years ago
parent
commit
9603413223
  1. 3
      components/enter-animation/demo/router.md

3
components/enter-animation/demo/router.md

@ -8,7 +8,6 @@ router 组合的进场与出场动画。
````jsx ````jsx
var ReactRouter = require('react-router'); var ReactRouter = require('react-router');
var history = require('react-router/lib/HashHistory').history;
var Router = ReactRouter.Router; var Router = ReactRouter.Router;
var Route = ReactRouter.Route; var Route = ReactRouter.Route;
var Link = ReactRouter.Link; var Link = ReactRouter.Link;
@ -72,7 +71,7 @@ var Page2 = React.createClass({
} }
}); });
React.render(( React.render((
<Router history={history}> <Router>
<Route path="/" component={App} ignoreScrollBehavior> <Route path="/" component={App} ignoreScrollBehavior>
<Route path="page1" component={Page1} /> <Route path="page1" component={Page1} />
<Route path="page2" component={Page2} /> <Route path="page2" component={Page2} />

Loading…
Cancel
Save