typescript-libraries
Version:
To install this library, run:
29 lines (28 loc) • 1.63 kB
TypeScript
export declare class TSObject {
static empty(object?: {}): boolean;
static value(object?: {}): any;
static fcAsKey(key: string): any;
static paths(text: string): RegExpMatchArray;
static property(text: string): string;
static propertyEscape(text: string): string;
static getBy(object: any, path: string, value?: any): any;
static setBy(o: any, s: any, path?: string): any;
static mergeBy(o: any, s: any, path?: string): any;
static updateBy(o: any, s: any, path?: string): any;
static deleteBy(object: any, pathToDelete: string, pathToReturn?: string): any;
static copyProperties(target: any, source: any, force?: boolean): void;
static cleanProperties(source: any, properties?: any): any;
static propertySet(o: any, k: string, v?: any): string;
static forOwn(object: any, callback: (v: any, k: string | number) => void): void;
static operateBy(o: any, s: any, type?: string, p0?: any, p1?: any, p2?: any, p3?: any): any;
static workBy(o: any, s: any, type?: string): any;
static merge(target: any, source: any, full?: boolean): any;
static clone(object: any): any;
static flat(current: any, property?: string, paths?: string[], cb?: (id: any, data: any) => void): {};
static enumValues(entity: any, type?: 'string'): string[];
static enumValues(entity: any, type?: 'number'): number[];
static toDictionary(array: Array<any>, kName: any, vName: any, ...args: any[]): any;
static reduceObject(object: any, ...args: any[]): any;
static normalizeObject(object: any): any;
static valueOrArrayValue(object: any, key: any): any;
}