How to add a history record with react?

1. That is, I want to change the url of my current page by clicking on the event, and then render another component, such as / admin/index to / admin/index?id=123
2. The page is still the current page, but when my url changes, I click the back button to fall back from / admin/index?id=123 to the status of / admin/index
3. Ask the bosses to help

Mar.01,2021

try using redux to manage route?


to change with react-router, you can use the

of the back button.
Menu