Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html >
<head>
  <script src="https://code.jquery.com/jquery.min.js"></script>
  <link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
  <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
  <script src="https://rawgit.com/angular/bower-angular/master/angular.min.js"></script>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>Lesson</title>
</head>
<body ng-app="myApp">
  <div class="container">
    <div class="well" ng-controller="myCtrl">
      <h1>My list</h1>
      <h3 ng-class="{'text-danger': $even}" ng-repeat="(key, el) in list track by $index">{{ key }}. {{ el }}</h3>
    </div>    
  </div>
</body>
</html>
 
angular.module("myApp", [])
.controller("myCtrl", ['$scope', function($scope) {
  
  //$scope.list = ["a", "a", "b", "c", "d", "e", "f"]; 
  $scope.list = {
    one: "a string",
    two: "another string"
  }
  
}]);
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
gmitticapro
0viewers