a8m / angular-filter

Bunch of useful filters for AngularJS (with no external dependencies!)
https://github.com/a8m/angular-filter
MIT License
2.93k stars 332 forks source link

can angular-filter groupby object #230

Open mrpsweet opened 7 years ago

mrpsweet commented 7 years ago
$scope.players = [
  {name: 'Gene', team: 'alpha'},
  {name: 'George', team: 'beta'},
  {name: 'Steve', team: 'gamma'},
  {name: 'Paula', team: 'beta'},
  {name: 'Scruath', team: 'gamma'}
];
groupBy: 'team'

I know this ok.

can angular-filter groupby do this?

$scope.players = [
  {1,{name: 'Gene', team: 'alpha'}},
  {2,{name: 'George', team: 'beta'}},
  {3,{name: 'Steve', team: 'gamma'}}
];
groupBy: 'team'

yeah it's not {key,value}