ng-repeat Directive
In Hindi
ng-repeat AngularJS का एक built-in directive है।
इसका उपयोग list या array के data को बार-बार display करने के लिए किया जाता है।
In English
ng-repeat is a built-in directive of AngularJS.
It is used to repeat HTML elements for each item in a list or array.
Example
<!DOCTYPE html>
<html ng-app="">
<head>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js"></script>
</head>
<body>
<div ng-init="students=['Rahul','Amit','Sohan']">
<ul>
<li ng-repeat="x in students">
{{ x }}
</li>
</ul>
</div>
</body>
</html>
Output:-
Rahul
Amit
Sohan
ng-show Directive In Hindi
ng-show AngularJS का built-in directive है।
यह condition true होने पर HTML element को दिखाता है।
In English
ng-show is a built-in directive of AngularJS.
It displays an HTML element when the condition is true.
Example
<!DOCTYPE html>
<html ng-app="">
<head>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js"></script>
</head>
<body>
<input type="checkbox" ng-model="showText">
<h2 ng-show="showText">
Welcome Students
</h2>
</body>
</html>
output:-
ng-hide Directive In Hindi
ng-hide AngularJS का built-in directive है।
यह condition true होने पर HTML element को छिपाता (hide) है।
In English
ng-hide is a built-in directive of AngularJS.
It hides an HTML element when the condition is true.
Example
<!DOCTYPE html>
<html ng-app="">
<head>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js"></script>
</head>
<body>
<input type="checkbox" ng-model="hideText">
<h2 ng-hide="hideText">
Hello Students
</h2>
</body>
</html>
Output