s-yadav / angulargrid

Pinterest like responsive masonry grid system for angular
MIT License
277 stars 105 forks source link

Add callback after grid layout. #120

Open antisilent opened 7 years ago

antisilent commented 7 years ago

re: #115: Added a callback when grid layout has finished...

<!-- template -->
<div angular-grid="items" ag-callback="agCallback()"></div>
// controller
function gridController($scope) {
  $scope.agCallback = function () {
    // emit an event to grid items, for example
    $scope.$broadcast('angulargrid:done');
  }
}