component-min
v1.0.0
Published
Min value utility
Downloads
6
Readme
min
Min value utility
Installation
$ component install component/min
API
min(array)
Return the min value in array
:
min([1,5,6,1,2,0])
min(array, fn)
Min value in array
with callback fn(val, i)
:
var age = min(users, function(u){ return u.age })
min(array, string)
Min value in array
with the given property string
:
var age = min(users, 'age')
License
MIT