optimizing shouldComponentUpdate