title: Setting interval timer to select value in React.js
body: <p>I have a function that I want to fire every x seconds based on how many seconds the user chooses from a dropdown. </p>
  
  <p>The function (which works when I just type in a number)</p>
  
  <pre><code>refreshNames(){
      setInterval(this.getNames, 1000);
    };
  </code></pre>
  
  <p>The JSX:</p>
  
  <pre><code>&lt;select id="timerInterval"&gt;
      &lt;option value="5"&gt;1 sec&lt;/option&gt;
      &lt;option value="10"&gt;2 sec&lt;/option&gt;
      &lt;option value="15"&gt;3 sec&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>If I replace 1000 with {timer}, how can I then set {timer} to the selected value?</p>