Answers for "angular display hide"

1

angular.io hide

<div [style.visibility]="(numberOfUnreadAlerts == 0) ? 'hidden' : 'visible' ">
   COUNTER: {{numberOfUnreadAlerts}} 
</div>
Posted by: Guest on November-28-2020
2

hide and show in angular 8

isShown: boolean = false ; // hidden by default


toggleShow() {

this.isShown = ! this.isShown;

}
Posted by: Guest on June-02-2020

Browse Popular Code Answers by Language