title: JS: I am trying to understand event emitters vs event listeners
body: <p>I am trying to understand the difference between event handlers and event emitters.
  I understand event <em>listeners</em> and how to attach them, for example, the following:</p>
  
  <pre><code>let element = document.getElementById('test-id');
  
  element.addEventListener('click', handleClick)
  })
  
  function handleClick() {
      console.log("is this function considered an event handler?")
  }
  </code></pre>
  
  <p>But even after reading about event emitters and handlers, I don't know exactly how or where they come into play.  </p>