AngularJS - ngIf Vs. ngShow

2017-05-16 JavaScript

At a first look, ng-if and ng-show seems logically very similar except one major difference.

ngShow (or ng-show)

ng-show will be generating the whole element at a time of rendering a web page. However, it will be hidden the element using angular class in case of false condition.

In simple words, the element, where the ng-show has been declared over that will be available on a web page (including its child elements) and can be seen by removing angular specific class that hides them.

Continue reading