title: setState called in ComponentDidMount is not updating the state?
body: <p>I am new to react-native and I am here trying to update the state when the component is loaded. however the state is not updating.</p>
  
  <pre><code>constructor(props) {
  super(props);
  
  this.state = {
   selectedSection: 'None',
   sectionObject: { index: 0, key: ''},
   sectionIndex: 0,
   sectionArray: [],
   };
  }
  
  componentDidMount()
  {
   this.setState({
   sectionObject: { index: this.state.sectionIndex, key: this.state.selectedSection},
   sectionArray: this.state.sectionArray.concat(this.state.sectionObject),
   })
   console.log('sectionObject:',this.state.sectionObject);
   console.log('section array:',this.state.sectionArray);
  }
  </code></pre>
  
  <p>What am I doing wrong here?</p>