title: Dynamic row heights with react-virtualized and new CellMeasurer
body: <p>I'm using react-virualized 9 with Autosizer, List, and CellMeasurer components.  I need to update the row heights when the list data has changed.  It appears that since the changes to support React Fiber in version 9 the only public method for CellMeasurer is now measure(). Most of the examples use the previous resetMeasurementForRow() method.  The current <a href="https://github.com/bvaughn/react-virtualized/blob/master/docs/CellMeasurer.md" rel="noreferrer">CellMeasurer doc</a> doesn't seem to have any info on the new public methods. Not sure if I've overlooked something but any help is appreciated.  </p>
  
  <pre><code>const cache = new CellMeasurerCache({
    defaultHeight: 60,
    fixedWidth: true
  });
  
  &lt;AutoSizer&gt;
    {({ width, height }) =&gt; (
      &lt;List
        deferredMeasurementCache={cache}
        height={height}
        ref={element =&gt; { this.list = element; }}
        rowCount={list.length}
        rowHeight={cache.rowHeight}
        rowRenderer={this.rowRenderer}
        width={width}
      /&gt;
    )}
  &lt;/AutoSizer&gt;
  
  rowRenderer({ index, key, parent, style }) {
    return (
      &lt;CellMeasurer
        cache={cache}
        columnIndex={0}
        key={key}
        overscanRowCount={10}
        parent={parent}
        ref={element =&gt; { this.cellMeasurer = element; }}
        rowIndex={index}
      &gt;
        {({ measure }) =&gt; {
          this.measure = measure.bind(this);
  
          return &lt;MyList index={index} data={list[index]} style={style} /&gt;;
        }}
      &lt;/CellMeasurer&gt;
    );
  }
  
  componentWillReceiveProps(nextProps) {
    // Some change in data occurred, I'll probably use Immutable.js here
    if (this.props.list.length !== nextProps.list.length) {
      this.measure();
      this.list.recomputeRowHeights();
    }
  }
  </code></pre>