title: How to remove an eventhandler document.onkeydown?
body: <p>I have this code, I would need programmatically overridde or remove onkeydown from document (for example using a simple condition)</p>
  
  <pre><code>document.onkeydown = function (f) {
      myMethod();
  };
  </code></pre>
  
  <p>Any idea how to do it?</p>