2

I am wondering what the difference between ngIf and ng-if is. In some sources I have seen ngIf used and in some sources ng-if used. I know ngIf vs *ngIf. That is not my question so do not get confused with that question. The dash is what I do not understand.

George Xavier
  • 191
  • 2
  • 12

1 Answers1

2

According to Angular documentation, ngIf is an Angular (v +2) directive , however, ng-if is an AngularJS (v 1.x) directive.

as also mentioned by @rcoro in comments.

aelagawy
  • 557
  • 5
  • 16