title: convert HH:mm to Date object in js
body: <p>If I have two times presented as strings like</p>
  
  <pre><code>14:10 and 19:02
  </code></pre>
  
  <p>how can I convert to Date object in order to get substracted value </p>
  
  <pre><code>var res = date1 - date2;
  </code></pre>
  
  <p>I tried to parse with </p>
  
  <pre><code>var date = new Date.parseExact(myDateVar, "HH:mm");
  </code></pre>
  
  <p>I'm getting </p>
  
  <blockquote>
    <p>Uncaught TypeError: Date.parseExact is not a constructor</p>
  </blockquote>