/** * Array Utilities * Common array manipulation helpers */ /** * Creates an array of specified length and maps over it * Alternative to Array.from({ length }).map() which is more verbose * * @param length - Length of array to create * @param mapFn - Map function (receives index) * @returns Mapped array * * @example * createMappedArray(5, (i) => i * 2) // [0, 2, 4, 6, 8] */ export declare function createMappedArray(length: number, mapFn: (index: number) => T): T[]; /** * Safely slice array to specified length * Returns empty array if input is null/undefined */ export declare function safeSlice(array: T[] | undefined, start: number, end?: number): T[]; /** * Filter array by ID * Returns new array with item matching ID removed */ export declare function filterById(array: T[], idToRemove: string): T[]; /** * Find item in array by ID */ export declare function findById(array: T[], id: string): T | undefined;