tail
arrayGets all but the first element of array.
Signature
tail<T>(array: T[]): T[]Parameters
| Name | Type | Description |
|---|---|---|
array | T[] | The array to query |
Returns
T[] - Returns the slice of array
Examples
Basic usage
import { tail } from 'dashlite'
const result = tail([1, 2, 3])
console.log(result)Output:
[2, 3]Available since version 1.0.0