title: Reactjs - `component` vs `render` in Route
body: <p>I have two doubts regarding usage of <code>Route</code> from <code>react-router-dom</code>(<strong>v4.3.1</strong>):</p>
  
  <ol>
  <li><p>When do we use <code>component</code> vs <code>render</code> in <code>Route</code>:</p>
  
  <pre><code>&lt;Route exact path='/u/:username/' component={ProfileComponent} /&gt;
  &lt;Route exact path='/u/:username/' render={() =&gt; &lt;ProfileComponent /&gt;} /&gt;
  </code></pre></li>
  <li>How to access the variable <code>username</code> in the <strong>URL</strong> in both ways?</li>
  </ol>