title: This is not a function while using in click event listener
body: <p>I am working on a javascript file and have code like following</p>
  
  <pre><code>class test(){
      constructor(){
      }
      showBox(){
          var countBlock = document.createElement("div");
          document.body.appendChild(countBlock); 
          countBlock.addEventListener('click', function(){
              this.showList()
          });
      }
      showList(){
          console.log('Element clicked')
      }
  }
  </code></pre>
  
  <p>Code is working fine unless I click on element, when I click it shows <code>this.showList() is not a function</code> </p>
  
  <p>Not sure how to resolve it</p>