emberjs/ember.js — pull request #4130 by onechiporenko (2014-01-13 13:00:40+00:00)
Title: [FEATURE] 3 new methods to Ember.Enumerable (2)

I couldn't modify this [pull-request](https://github.com/emberjs/ember.js/pull/3967), so had to create new one.
Copy description:

**compactBy**
Returns a copy of the array without elements with `key` equal to `null` and `undefined`.
```javascript
var arr = [Ember.Object.create({a: null}), {a: 1}, {a: false}, {a: ''}, {a: undefined}, {a: 0}, {a: null}];
arr.compactBy("a"); // [{a: 1}, {a: false}, {a: ''}, {a: 0}]
```
**maxBy**
Returns an object with maximum `key` value or `undefined` if all elements don't have `key`
```javascript
var arr = [{a: 2}, {a: 1}, {a: 3}, {a: 4}];
arr.maxBy("a"); // {a: 4}
```
**minBy**
Returns an object with minimum `key` value or `undefined` if all elements don't have `key`
```javascript
var arr = [{a: 2}, {a: 1}, {a: 3}, {a: 4}];
arr.minBy("a"); // {a: 1}
```