Gets all but the last element of array.
array
The array to query.
Returns the slice of array.
5.18.0
initial([1, 2, 3])// => [1, 2] Copy
initial([1, 2, 3])// => [1, 2]
Gets all but the last element of
array
.