ReactJS - 未呈现反应路由器嵌套路径

ReactJS - react-router nested path not rendered

我无法解决这个问题,我无法渲染我从 nested path 调用的 component 的 HTML,例如 /page/detail[=21] =]

我的路线树

render(
    (<Router history={history}>
        <Route path="/" component={App}>
            <IndexRoute component={Index}/>
            <Route path="page" component={Page}>
                <Route path="/page/detail" component={Detail} />
            </Route>
        </Route>
    </Router>),
    document.getElementById('main')
)

我的 {App} 组件呈现这个:

render() {
    return (
        <div>
            <nav className="navbar">
                <ul className="nav navbar-nav navbar-right">
                    <li><Link className="menu-link" ref="menu" to="/page">Page Test</Link></li>
                </ul>
            </nav>
            <div id="content-wrapper">{this.props.children}</div>
        </div>
    )
}

我的路由 /page/detail 是从组件 {Page} 内的 Link 调用的,但如果我访问此 link,我只会看到 {Page} 组件呈现的内容。我已经用 react-routers 搜索了一些关于嵌套路由的解决方案,但我没有找到答案。

更新:

通过这个解决方案,我渲染了我的 {Detail} 组件的 html: 我已将其插入 {Page} 组件

{this.props.children || <div>My Detail page</div> }

更新 2

在我的 {Page} 组件中,我插入了一个 jQuery plugin

mix() {
    $("#filter-gallery").mixItUp();
}

destroy() {
    $('#filter-gallery').mixItUp('destroy');
}

componentDidMount() {
    this.mix();
}

componentWillUnmount() {
    this.destroy();
}

此插件仅在 {Page} 刷新页面时有效,如果我导航至 /page/detail 然后返回 /page,则该插件无效。

我找到了这样设置路由的解决方案:

<Route path="studio" component={Studio} />
    <Route path="studio/detail" component={Calendar} />