Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

react router dom link same page with different param

componentDidUpdate(prevProps) {
   if(prevProps.match.params.id !== this.props.match.params.id){
     // do something
   }
 }
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #react #router #dom #link #page #param
ADD COMMENT
Topic
Name
5+5 =