1.0.1 • Published 7 years ago
array-n-first v1.0.1
array-n-first
Short package to get either the first n elements of an array or mid n elements of an array
Example
first([1,2,4,7],2)
// => [1,2]
midN([1,2,4,7],2,3)
// => [4,7]
Short package to get either the first n elements of an array or mid n elements of an array
first([1,2,4,7],2)
// => [1,2]
midN([1,2,4,7],2,3)
// => [4,7]