title: Force React to reload an image file?
body: <p>My React app allows users to upload profile images. This is done by uploading the image to an Amazon S3 bucket and storing the path to the image in my database, along with the date and time the image was uploaded. The filename of the image is set to the user's ID.</p>
  
  <p>Im having a problem when a user uploads a new image. As the image path is the same React doesn't know anything has changed, meaning I have to refresh the page to see the change. </p>
  
  <p>As I have a date field I can use componentWillReceiveProps to know when a new image has been uploaded. The following console.log does fire at the correct time: </p>
  
  <pre><code>componentWillReceiveProps(nextProps) {
      if (this.state.picDate.getTime() !== nextProps.user.pic.date.getTime()) {
          console.log('image date has changed');
          // this.forceUpdate();
      }
  }
  </code></pre>
  
  <p>Can I use this to re-render the image? I tried <code>this.forceUpdate()</code> but it doesn't work.</p>