unhandled Promise rejection: Failed to load
In the Following angular js code i m getting the below error unhandled Promise rejection: Failed to load app.test.html ; Zone: ; Task: Promise.then ; Value: Failed to load app.test.html undefined my code looks like below
1 2 3 4 5 6 7 |
import { Component } from '@angular/core'; @Component({ selector: 'my-app', templateUrl: 'app.test.html' }) export class AppComponent { apptitle:string='Welcome to the world of angularjs Mr Vasanthan';appstatus:boolean=true; } |
Solution:This issue because of wrong syntax. use templateUrl: ‘app/test.html’ instead of templateUrl: ‘app.test.html’.