code: function(newProps) {
          if (this.getInitialState) {
              if (this.getInitialProps) {
                  newProps = this.getInitialProps(newProps) || {};
              }
              var newState = this.getInitialState(newProps);
              this.replaceState(newState);
              return;
          }
  
          if (!this.__newProps) {
              updateManager.queueWidgetUpdate(this);
          }
  
          this.__newProps = newProps;
      }
docs: Recalculate the new state from the given props using the widget's
  getInitialState(props) method. If the widget does not have a
  getInitialState(props) then it is re-rendered with the new props
  as input.
  
  @param {Object} props The widget's new props