Skip to main content

Posts

Showing posts with the label ng-show

AngularJs - ng-repeat with $index, $first, $middle, $last, $even, $odd, ng-if, ng-show, ng-hide

Use of ng-repeat Variables: 1.        $index :number ,iterator offset of the repeated element (0...length-1) 2.        $first : boolean true, if the repeated element is first in the iterator. 3.        $middle : boolean true, if the repeated element is between the first and last in the iterator. 4.        $last : Boolean true, if the repeated element is last in the iterator. 5.        $even :Boolean true, if the iterator position $index is even (otherwise false). 6.        $odd :Boolean true, if the iterator position $index is odd (otherwise false). Example in details, < !DOCTYPE html > < html > < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js"></ script > < body ng-app =" myApp " ng-controller =" myCtrl "> ...