UNPKG

1.19 kBTypeScriptView Raw
1// Type definitions for extend 3.0
2// Project: https://github.com/justmoon/node-extend
3// Definitions by: Stefan Steinhart <https://github.com/reppners>
4// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
5
6declare function extend<T, U>(deep: boolean, target: T, source: U): T & U;
7declare function extend<T, U, V>(deep: boolean, target: T, source1: U, source2: V): T & U & V;
8declare function extend<T, U, V, W>(deep: boolean, target: T, source1: U, source2: V,
9 source3: W): T & U & V & W;
10declare function extend<T, U, V, W, X>(deep: boolean, target: T, source1: U, source2: V,
11 source3: W, source4: X): T & U & V & W & X;
12declare function extend<T, U>(target: T, source: U): T & U;
13declare function extend<T, U, V>(target: T, source1: U, source2: V): T & U & V;
14declare function extend<T, U, V, W>(target: T, source1: U, source2: V, source3: W): T & U & V & W;
15declare function extend<T, U, V, W, X>(target: T, source1: U, source2: V,
16 source3: W, source4: X): T & U & V & W & X;
17declare function extend(deep: boolean, target: any, ...sources: any[]): any;
18declare function extend(target: any, ...sources: any[]): any;
19declare namespace extend {}
20export = extend;