How to refresh the parameters of React Router v4 without losing them?

related codes

is there any other way than the following?
Route definition method:

<Route path="/path/:name" component={Path}/>

Link component:

<Link to="/path/"></Link>

Parameter acquisition:
this.props.match.params.name -sharp-sharp-sharp problem description

what methods have you tried

query No!
state No!

what result do you expect? What is the error message actually seen?

js jumps, the parameters are taken, and the page refresh parameters are not lost.

Apr.12,2022

answer your own questions. Now my approach is to use search , and then go to the desired page to go to the address bar and use qs to get it.

if you have different opinions, please reply or leave a message.

Menu