Skip to content Skip to sidebar Skip to footer

Unexpected Closing Tag "div" Error Angular2 Html

I'm getting some errors in the console and not sure what is the issue is in the HTML. Any help would be appreciated. error_handler.js:51 EXCEPTION: Uncaught (in promise): Error: T

Solution 1:

You've got one double quote too many at *ngIf="errorMessage && !successMessage"":

<divclass="alert alert-dismissible alert-danger outer-top-xs" *ngIf="errorMessage && !successMessage"><!--at the end of this line-->

Solution 2:

This error occurred when you open an element and don't close its. this error shows up in this example:

<ion-list *ngSwitchCase="'facilities'"><ion-item *ngFor="let facility of facilities"><ion-iconname="facility.Icon"item-start></ion-icon>
  {{facility.Name}}
  <ion-iconcolor="red"name="rose"item-end></ion-icon></ion-item><ion-list>

As you see I don't close <ion-list> element (should be </ion-list>)

Be careful:

If you use any element properties with its values as the parser can't handle them, the element will be opened and this error occurs( "" at above example).

Post a Comment for "Unexpected Closing Tag "div" Error Angular2 Html"