<Router>
<Switch>
<Route exact path="/" component={Index}/>
<Route exact path="/explore" component={Explore}/>
</Switch>
</Router>
Index.js
<Layout>
<Grid>
...
</Grid>
</Layout>
Layout.js
<div>
<main>
{this.props.children}//我现在想将Layout里面的值传到Index组件里面,请问该如何做?
</main>
</div>