title: Why there is not type safety in angular for DOM like there is in typescript?
body: <p>In typescript when we do this</p>
  <pre><code>let x = document.querySelector('a');
  console.log(x.href);
  </code></pre>
  <p>we get error that <code>Object is possibly null</code></p>
  <p>but when i do the same for example in Angular ( we know that angular uses typescript ) in the component</p>
  <pre><code> ngOnInit() {
      let x = document.querySelector('a');
      console.log(x.href);
    }
  </code></pre>
  <p>i don't get any compilation time error.</p>
  <p>Why is that ?</p>