title: componentWillReceiveProps vs getDerivedStateFromProps
body: <p>What exactly componentWillReceiveProps and getDerivedStateFromProps are subtle question for me. Because, I just came across to an issue while using getDerivedStateFromProps:</p>
  
  <pre><code>// Component 
  state = {
    myState: []
  }
  
  // Using this method works fine:
  
  componentWillReceiveProps(nextProps) {
    this.setState({
      myState: nextProps.myPropsState
    })
  }
  
  // But using this method will cause the checkboxes to be readonly:
  
  static getDerivedStateFromProps(nextProps,prevProps) {
    const { myPropsState: myState } = nextProps
    return {
      myState
    }
  }
  
  // And here's checkbox
  &lt;input type="checkbox" id={`someid`} 
   onChange={(e) =&gt; this.handleMethod(e, comp.myState)} 
   checked={myState.indexOf(comp.myState) &gt; -1} /&gt;
  </code></pre>
  
  <p><strong>React version: 16.4.1</strong></p>