//#region src/collection/partition.d.ts /** * Creates an array of elements split into two groups, the first of which contains elements predicate returns truthy for, the second of which contains elements predicate returns falsy for * @param collection - The collection to iterate over * @param predicate - The function invoked per iteration * @returns Returns the array of grouped elements * @example * const users = [ * { name: 'John', active: true }, * { name: 'Jane', active: false }, * { name: 'Bob', active: true } * ]; * partition(users, 'active'); * // => [[{name: 'John', active: true}, {name: 'Bob', active: true}], [{name: 'Jane', active: false}]] */ declare function partition(collection: T[], predicate: ((item: T, index: number) => boolean) | string): [T[], T[]]; //#endregion export { partition }; //# sourceMappingURL=partition.d.cts.map