title: React promise resolution not resulting in render
body: <p>So I have a component that performs an API call that gets returned via Promise:</p>
  
  <pre><code>getStuff(url).then(val =&gt; this.setState(prevState =&gt; {prevState.alltime = val}));
  </code></pre>
  
  <p>this is getting called in componentDidMount and is successfully resolving to an array in state.</p>
  
  <p>I also have a component that I am mapping this array into,</p>
  
  <pre><code> const relevantData = this.state[this.state.sortType];
  let items= &lt;p&gt; no data&lt;/p&gt;;
  if (relevantData){
    items = relevantData.map((prop, i) =&gt; {
    prop.i = i;
    return(&lt;BoardItem prop={prop} i={i} key={i}/&gt;)})
  }
  </code></pre>
  
  <p>and then in the render function</p>
  
  <pre><code>&lt;div&gt; {items} &lt;/div&gt;
  </code></pre>
  
  <p>nothing renders when I see the promise resolve in the console,  but the next time I render irrelevant state, (such as running $r.setState({test:'test}) in react devtools)  everything renders out.</p>