I don't think I'm fully understanding how I can make routing work when nested I have it structured this way because I need changes in SideDrawer to affect the Article component and I haven't found a way to pass props down from a parent component to it's children through routing. Currently all the routes are working except for "/innerbrowser/easynhknews/articles/:id" Let me know if there is a better way to structure this and still attain the function I want
App.js
class App extends Component {
render() {
return (
<div>
<Frame>
<Switch>
<Route path="/" exact component={Dashboard} />
<Route path="/innerbrowser" component={InnerBrowser} />
</Switch>
</Frame>
</div>
);
}
}
InnerBrowser.js
class InnerBrowser extends Component
{
//unrelated code.....
render() {
return (
<div className={classes.InnerBrowser}>
<SideDrawer />
<div className={classes.InnerBrowserBody}>
<Switch>
<Route path="/innerbrowser/easynhknews/articles/:id" exact render={() => <Article />}/>
<Route path="/innerbrowser/easynhknews" render={() => <ArticleTiles />}/>
</Switch>
</div>
</div>
);
}
}