wildcard link to parent route reactjs -
let's have class handler respond on both /handle , /handle/:id.
have problem :
component(in case , handler class ) shown on both pages has buttons take me 1 other, example button gets me /handle /handle/195 , gets me /handle/195 /handle.
so button on /handle having:
onclick={()=>{hashistory.push('/handle/195')}}
which works perfectly, 1 on /handle/195 with:
onclick={()=>{hashistory.push('/handle')}}
does not, know how redirect parent url using hashistory? apologize if problem poorly explained. tried best.
thanks.
Comments
Post a Comment