title: Downsides of onMousedown vs. onClick?
body: <p>I've been dealing with a bane-of-my-existence Javascript problem involving tracking when a user clicks on a link (in case you're curious, here it is: <a href="https://stackoverflow.com/questions/1629158/why-does-using-targetblank-cause-javascript-to-fail">Why does using target=&quot;_blank&quot; cause Javascript to fail?</a>).</p>
  <p>I've figured out that I can solve the problem by tracking an <code>onMousedown</code> event rather than an <code>onClick</code> event.</p>
  <p>I'm curious about the downsides of this approach.  The ones I can think of:</p>
  <ol>
  <li>If a user clicked down on a link and then moved the mouse off the link before releasing it, then the event would be recorded even though the user hadn't visited the link</li>
  <li>If a user used the tab key to move the browser focus to the link and then hit enter, the click would not be recorded</li>
  </ol>
  <p>Neither of these are common, so I'm not terribly worried about them.</p>
  <p>Are there any other downsides I'm missing?</p>