UNPKG

next-sitemap

Version:
25 lines (24 loc) 792 B
/** * Split an array based on size * @param arr * @param chunkSize * @returns */ export declare const toChunks: <T>(arr: T[], chunkSize: number) => T[][]; /** * simple method to normalize any string to array * @param inp */ export declare const toArray: (inp: string | string[]) => string[]; /** * Returns the difference between two arrays * @param inputArr input array * @param toRemoveArr array of elements to be removed */ export declare const removeFromArray: <T>(inputArr: T[], toRemoveArr: T[]) => T[]; /** * Returns the difference between two arrays, which match input array pattern * @param inputArr input array * @param toRemoveArr array of elements to be removed */ export declare const removeIfMatchPattern: (inputArr: string[], toRemoveArr: string[]) => string[];