Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html ng-app="app">
<head>
<script src="http://code.jquery.com/jquery.min.js"></script>
<script  src="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.7/angular.min.js"></script>
<script>%code%</script>
<meta charset=utf-8 />
<title>JS Bin</title>
  <style>
    .ngFooterSelectedItems {
      display: none;
    }
  </style>
</head>
<body ng-controller="Controller">
  
 <div class="section">
   <div style="height: 450px; width: 100%;" ng-grid="myGrid"></div>
   <div remove-element="div.ngFooterTotalItems"></div>
 </div>
  
 <script>
   var app = angular.module('app', ['ngGrid']);
   
   
   app.controller('Controller', function ($scope) {
     
     $scope.myData = [{name: "Moroni", age: 50},
                     {name: "Tiancum", age: 43},
                     {name: "Jacob", age: 27},
                     {name: "Nephi", age: 29},
                     {name: "Enos", age: 34}];
     
     $scope.myGrid = { data: 'myData',
                      showFooter: true};
   });
   
   app.directive('removeElement', function () {
     return {
       link: function (scope, element, attrs) {
         
         var offendingElement,
             offendingElementSelector = attrs.removeElement;
         scope.$watch(function () {
           offendingElement = $(offendingElementSelector);
           return offendingElement.css('display');
         }, function (newValue, oldValue) {
           if ( newValue !== 'none' ) {
             console.log(newValue);
             offendingElement.hide();
           }
         });
       }
     };
   });
   
 </script>
</body>
</html>
Output

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

Dismiss x
public
Bin info
mgemmillpro
0viewers