title: immutable.js & react.js setState clears prototype of the object
body: <p>I have the following code in component:</p>
  
  <pre><code>constructor() {
      this.state = Immutable.fromJS({
              user : {
                  wasChanged : false,
                  firstName : false,
                  lastName : false,
                  address : {
                      street : false,
                  }
              }
          });
  }
  onEdit({target: {dataset: {target}}}, value) {
        this.setState(function (prevState) {
            return prevState.setIn(['user', target], value);
          });
    }
  render() {
      var user = this.state.get('user').toJS();
      ...
  }
  </code></pre>
  
  <p>The problem is that when I try to update the value in <em>onEdit</em> I see that <em>prevState</em> has different prototype set. I don't understand why or what am I doing wrong. I see this in console</p>
  
  <pre><code>&gt; Object.getPrototypeOf(this.state)
  src_Map__Map {@@__IMMUTABLE_MAP__@@: true}
  
  &gt; Object.getPrototypeOf(prevState)
  Object {}
  </code></pre>
  
  <p>After the state has been changed it goes to render where it of course can't find <em>get</em> function or anything from Immutable</p>
  
  <p>Using react with addons 0.13.3.</p>