(items: Array<T>, item: T, max = 0)
| 403 | } |
| 404 | |
| 405 | export function addToStart<T>(items: Array<T>, item: T, max = 0): Array<T> { |
| 406 | const newItems = [item, ...items] |
| 407 | return max && newItems.length > max ? newItems.slice(0, -1) : newItems |
| 408 | } |
| 409 | |
| 410 | export const skipToken = Symbol() |
| 411 | export type SkipToken = typeof skipToken |
no outgoing calls
no test coverage detected
searching dependent graphs…