MultiLoader-Template/node_modules/es-toolkit/dist/compat/array/tail.d.mts
3944Realms 768f38fc97 feat: 可使用的构建模板
修改了脚本,使其可以推给Maven仓库
2026-05-03 13:02:19 +08:00

27 lines
638 B
TypeScript

/**
* Gets all but the first element of array.
*
* @template T
* @param {readonly [unknown, ...T]} array - The array to query.
* @returns {T} Returns the slice of array.
*
* @example
* tail([1, 2, 3]);
* // => [2, 3]
*/
declare function tail<T extends unknown[]>(array: readonly [unknown, ...T]): T;
/**
* Gets all but the first element of array.
*
* @template T
* @param {ArrayLike<T> | null | undefined} array - The array to query.
* @returns {T[]} Returns the slice of array.
*
* @example
* tail([1, 2, 3]);
* // => [2, 3]
*/
declare function tail<T>(array: ArrayLike<T> | null | undefined): T[];
export { tail };