I want to associate a specific section of a page section with a responsive router in much the same way that anchor tags will work in html. However, I could not find a solution with React Router version 1.0.0.
I currently have my router:
let history = createHashHistory({
queryKey: false
});
<Router history={history}>
<Route path="/" component={a}/>
<Route path="/b" component={b}/>
<Route path="/c" component={c}/>
<Route path="/d" component={d}/>
<Route path="/e" component={e}/>
<Route path="/f" component={f}/>
<Route path="/g" component={g}/>
</Router>
and I'm trying to reference a specific section in components like
<Link to="/b#{div_id}"> Go to section with div_id is component {b} </Link>
source
share