/** * Checks if an array type is a tuple (fixed length) or regular array. * * Returns `true` for tuple types like `[string, number]` where length is fixed, * and `false` for array types like `string[]` where length is variable. * * @template T Array or tuple type to check */ export type IsTuple = [ T ] extends [never] ? false : T extends readonly any[] ? number extends T["length"] ? false : true : false;