title: Angular failed to compile due to error in HostResourceLoader
body: <p>I'm new to angular, I have an angular project that whenever I run <code>npm start</code> or <code>ng serve</code> it comes up with an error-</p>
  <p><code>ERROR in HostResourceLoader: loader(D:/Spark/doPayroll clone/dopayroll-front-end/src/app/getstarted/getstarted.component.html) returned a Promise</code>.</p>
  <p>I have to press ctrl + s in any of my files in order for the app to reload and compiles successfully, I've searched all over the internet but non of the answers worked in my case.</p>
  <p>I'm using Angular 6.1.5.</p>
  <p><strong>getStarted.component.html</strong></p>
  <pre><code>&lt;div class=&quot;main&quot;&gt;
  &lt;div class=&quot;welcome&quot;&gt;
      &lt;p [translate]=&quot;'getstarted.title'&quot;&gt;
      &lt;/p&gt;
  &lt;/div&gt;
  &lt;hr class=&quot;underline&quot;&gt;
  &lt;img width=&quot;300&quot; src=&quot;assets/img/welcome.png&quot;&gt;
  &lt;p class=&quot;welcome2&quot; [translate]=&quot;'getstarted.body'&quot;&gt;&lt;/p&gt;
  &lt;button (click)=&quot;next()&quot; class=&quot;button button4&quot; [translate]=&quot;'getstarted.next'&quot;&gt;&lt;/button&gt;
  &lt;/div&gt;
  </code></pre>
  <p><strong>getStarted.component.ts</strong></p>
  <pre class="lang-js prettyprint-override"><code>export class GetstartedComponent implements OnInit {
    
      constructor(private router: Router) {}
  
      next(){
        this.router.navigate(['/presignup']);
      }
  
      ngOnInit() {
      }
  
  }
  </code></pre>