getDerivedStateFromProps() looks like it can replace the use of componentWillReceiveProps() here
componentWillReceiveProps()