title: What is the best way to redirect a page using React Router?
body: <p>I am new to React Router and learn that there are so many ways to redirect a page:</p>
  
  <ol>
  <li><p>Using <code>browserHistory.push("/path")</code></p>
  
  <pre><code>import { browserHistory } from 'react-router';
  //do something...
  browserHistory.push("/path");
  </code></pre></li>
  <li><p>Using <code>this.context.router.push("/path")</code></p>
  
  <pre><code>class Foo extends React.Component {
      constructor(props, context) {
          super(props, context);
          //do something...
      }
      redirect() {
          this.context.router.push("/path")
      }
  }
  
  Foo.contextTypes = {
      router: React.PropTypes.object
  }
  </code></pre></li>
  <li><p>In React Router v4, there's <code>this.context.history.push("/path")</code> and <code>this.props.history.push("/path")</code>. Details: <a href="https://stackoverflow.com/questions/42701129/how-to-push-to-history-in-react-router-v4">How to push to History in React Router v4?</a></p></li>
  </ol>
  
  <p>I'm so confused by all these options, is there a best way to redirect a page?</p>