Gets the first element of array.
array
The array to query.
Returns the first element of array.
5.0.0
first
last
head([1, 2, 3])// => 1head([])// => undefined Copy
head([1, 2, 3])// => 1head([])// => undefined
Gets the first element of
array
.