angular hidden code example
Example 1: hide and show in angular 8
/* Component */
isShown: boolean;
ngOnInit(){
isShown = false; //hidden every time subscribe detects change
}
toggleShow() {
this.isShown = ! this.isShown;
}
/* Template */
<div *ngIf="isShown" class="row container-fluid" id="divshow">
content
</div>
Example 2: hidden property input angular 2
<p [style.display]="hideElement?'none':'inherit'">
I am using hidden.
</p>