title: DOMContentLoaded not getting fired in typescript
body: <p>I Am trying to fire DOMContentLoaded event in typescript after page load is completed.<br></p>
  
  <p>I am unable to figure out where to put <code>addEventListener('DOMContentLoaded', event ()=&gt;{})</code> line, so that I can query for elements loaded as of now I am putting this code in consstructor of my web component class but its not firing.<br></p>
  
  <p>Below is the code.</p>
  
  <pre><code> constructor() {
      super();
      document.addEventListener('DOMContentLoaded', (e) =&gt; {
          this.domCompleteHandler(e)
      }, false);
  }
   domCompleteHandler(e: Event) {
      //if (e.target!.readystatechange === "complete") {
          var chkbxes = document!.querySelector('my-app[apptitle="my app"]')!.shadowRoot!.querySelector('[active]')!.shadowRoot!.querySelector("#permSection")!.querySelector("#permtable")!.shadowRoot!.querySelector("#permtable")!.querySelectorAll(".permchk");
          chkbxes!.forEach(el =&gt; {
              el.addEventListener('click', (e) =&gt; {
                  this.clickHandler(e);
              });
          });
      console.log(e);
      console.log(chkbxes);
      //}
  }
  </code></pre>