/**
 * Return an object containing arrays organized by property
 *
 * @param array - The array to split
 * @param key - The object property to split by
 * @returns An object containing arrays separated by property value
 *
 * @example
 * interface MyObj {
 *   a: string;
 *   b: number;
 * }
 * const myArray: MyObj[] = [{a: 'foo', b: 1}, {a: 'bar', b: 6}, {a: 'foo', b: 6}];
 * groupBy<MyObj, keyof MyObj>(myArray, 'a');
 * Returns:
 *   {
 *     foo: [{a: 'foo', b: 1}, {a: 'foo', b: 6}],
 *     bar: [{a: 'bar', b: 6}],
 *   }
 */
export declare function groupBy<T, K extends (keyof T & (number | string))>(array: T[], key: K): {
    [id: string]: T[];
};
