min (dependentKey) Ember.ComputedPropertypublic
A computed property that calculates the minimum value in the dependent array. This will return Infinity when the dependent array is empty.
let Person = Ember.Object.extend({
  childAges: Ember.computed.mapBy('children', 'age'),
  minChildAge: Ember.computed.min('childAges')
});
let lordByron = Person.create({ children: [] });
lordByron.get('minChildAge'); // Infinity
lordByron.get('children').pushObject({
  name: 'Augusta Ada Byron', age: 7
});
lordByron.get('minChildAge'); // 7
lordByron.get('children').pushObjects([{
  name: 'Allegra Byron',
  age: 5
}, {
  name: 'Elizabeth Medora Leigh',
  age: 8
}]);
lordByron.get('minChildAge'); // 5
 If the types of the arguments are not numbers, they will be converted to numbers and the type of the return value will always be Number. For example, the min of a list of Date objects will be the lowest timestamp as a Number. This behavior is consistent with Math.min.
Parameters:
- 
dependentKey 
String 
Returns:
- 
Ember.ComputedProperty - computes the smallest value in the dependentKey's array
 
Please login to continue.