title: componentWillUnmount() not being called when refreshing the current page
body: <p>I've been having this problem where my code in the <code>componentDidMount()</code> method wasn't firing properly when refreshing the current page (and subsequently, the component). However, it works perfectly fine just navigating and routing through my website by clicking links. Refresh the current page? Not a chance.</p>
  
  <p>I found out that the problem is that <code>componentWillUnmount()</code> doesn't trigger when I refresh the page and triggers fine clicking links and navigating my website/app.</p>
  
  <p>The triggering of the <code>componentWillUnmount()</code> is crucial for my app, since the data that I load and process in the <code>componentDidMount()</code> method is very important in displaying information to users.</p>
  
  <p>I need the <code>componentWillUnmount()</code> to be called when refreshing the page because in my <code>componentWillMount()</code> function (which needs to re-render after every refresh) I do some simple filtering and store that variable in a state value, which needs to be present in the <code>logos</code> state variable in order for the rest of the component to work. This does not change or receive new values at any time during the component's life cycle.</p>
  
  <pre><code>componentWillMount(){
    if(dataReady.get(true)){
      let logos = this.props.questions[0].data.logos.length &gt; 0 ? this.props.questions[0].data.logos.filter((item) =&gt; {
        if(item.logo === true &amp;&amp; item.location !== ""){
          return item;
        }
      }) : [];
      this.setState({logos: logos});
    }
  };
  </code></pre>
  
  <p><strong>Cliffs:</strong></p>
  
  <ul>
  <li>I do DB filtering in <code>componentWillMount()</code>method</li>
  <li>Need it to be present in the component after refresh</li>
  <li>But I have a problem where the <code>componentWillUnmount()</code> doesn't trigger when the page is refreshed</li>
  <li>Need help</li>
  <li>Please</li>
  </ul>