有以下的React Router:
const AppRoutes = (
<Route path="/" handler={Properties}>
<DefaultRoute handler={PropertyList} />
<Route path="property/:propId" handler={PropertyDetail}/>
<NotFoundRoute handler={NotFound} />
</Route>);
Router.run(AppRoutes, Router.HashLocation, (Root) => {
React.render(<Root />, document.getElementById('filter-content'));
});
我试图在一个子组件中构建动态链接,下面是我的一个测试
<Link to="/property/" params={{ propId: "123"}} ><img src={this.props.data.picture}
data-srcset="http://placehold.it/350x150" alt="" className="lazyload auto-height"
data-sizes="auto"/>
</Link>
但是点击链接时,propId没有传递,请问我做错了什么?