oak-domain/lib/utils/lodash.d.ts

34 lines
1.3 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/**
* 避免lodash打包体积过大
* 像assign, keys尽量使用Object的函数
*/
import unset from 'lodash/unset';
import uniqBy from 'lodash/uniqBy';
import pull from 'lodash/pull';
import uniq from 'lodash/uniq';
import get from 'lodash/get';
import set from 'lodash/set';
import intersection from 'lodash/intersection';
import intersectionBy from 'lodash/intersectionBy';
import omit from 'lodash/omit';
import merge from 'lodash/merge';
import mergeWith from 'lodash/mergeWith';
import cloneDeep from 'lodash/cloneDeep';
import pick from 'lodash/pick';
import isEqual from 'lodash/isEqual';
import union from 'lodash/union';
import difference from 'lodash/difference';
import differenceBy from 'lodash/differenceBy';
import groupBy from 'lodash/groupBy';
import unionBy from 'lodash/unionBy';
import pullAll from 'lodash/pullAll';
/**
* merge两个对象遇到array时使用连接合并
* @param object
* @param source
* @returns
*/
declare function mergeConcatArray(object: any, source: any): any;
declare function mergeConcatMany<T>(array: Array<T>): T;
export { unset, pull, uniq, uniqBy, get, set, intersection, intersectionBy, omit, merge, mergeWith, mergeConcatArray, mergeConcatMany, cloneDeep, pick, isEqual, union, difference, differenceBy, groupBy, unionBy, pullAll, };