Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to delete props from url

  const checkDelete = this.props.location.state.deleted // true
  if(checkDelete){
   this.setState({
    messageAlert:true
   }, () => { 
      history.replace('/home/admins', {state: { deleted : false }}) // false
   }
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #delete #props #url
ADD COMMENT
Topic
Name
8+6 =