Laamiri Oussema
Laamiri Oussema

Reputation: 537

using ng-if in angular2

I'm trying to build an ionic2 application,the shedule application send notifications to users,i want to do something like this but it didn't worked

<div *ngIf="beacon.uuid=='ebefd083-70a2-47c8-9837-e7b5634df557'">{{schedule("ok","okkk")}}</div>

Upvotes: 0

Views: 54

Answers (1)

Vivek Doshi
Vivek Doshi

Reputation: 58593

Change you code to this :

<div *ngIf="beacon.uuid==='ebefd083-70a2-47c8-9837-e7b5634df557'">{{schedule("ok","okkk")}}</div>

Use === instead of == , in Angular 2.

Upvotes: 1

Related Questions