React router takes an extra step back to the last page

I am using react-router to route my application. In my application, when I am going to go to the profile page (with username) from the home page (eg .01) and after that click the back button, then I double click on the home page. Because it takes an extra step to remove (?) From url. Can anyone help me fix this.

I used this.transitionTo('profile', {username: username});

to go to profile page

eg.01:
file:///E:/react-new/public/index.html#/

beforefile:///E:/react-new/public/index.html?#/profile/iammerrick



+3


source to share





All Articles