I’m trying to compare values using ngIf and only show the div when it’s true. However, I cannot seem to solve this.
.TS code:
constructor(public navCtrl: NavController, public navParams: NavParams, public dp: DatabaseProvider) {
this.walletId = navParams.get('wallet_id');
this.walletName = navParams.get('name');
}
HTML code:
<ion-list>
<ion-item *ngFor="let item of histories" text-wrap>
<div *ngIf="item.wallet_id == [walletId]">
<p>Some content here</p>
</div>
</ion-item>
</ion-list>
Thank you!