Skip to content

File tree

1 file changed

+3
-30
lines changed

1 file changed

+3
-30
lines changed

lib/lib.es2015.core.d.ts

Lines changed: 3 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -281,37 +281,10 @@ interface ObjectConstructor {
281281
* Copy the values of all of the enumerable own properties from one or more source objects to a
282282
* target object. Returns the target object.
283283
* @param target The target object to copy to.
284-
* @param source The source object from which to copy properties.
284+
* @param sources The source objects from which to copy properties.
285285
*/
286-
assign<T, U>(target: T, source: U): T & U;
287-
288-
/**
289-
* Copy the values of all of the enumerable own properties from one or more source objects to a
290-
* target object. Returns the target object.
291-
* @param target The target object to copy to.
292-
* @param source1 The first source object from which to copy properties.
293-
* @param source2 The second source object from which to copy properties.
294-
*/
295-
assign<T, U, V>(target: T, source1: U, source2: V): T & U & V;
296-
297-
/**
298-
* Copy the values of all of the enumerable own properties from one or more source objects to a
299-
* target object. Returns the target object.
300-
* @param target The target object to copy to.
301-
* @param source1 The first source object from which to copy properties.
302-
* @param source2 The second source object from which to copy properties.
303-
* @param source3 The third source object from which to copy properties.
304-
*/
305-
assign<T, U, V, W>(target: T, source1: U, source2: V, source3: W): T & U & V & W;
306-
307-
/**
308-
* Copy the values of all of the enumerable own properties from one or more source objects to a
309-
* target object. Returns the target object.
310-
* @param target The target object to copy to.
311-
* @param sources One or more source objects from which to copy properties
312-
*/
313-
assign(target: object, ...sources: any[]): any;
314-
286+
assign<Source extends {}, Result extends Source>(target: Source, ...sources: Source[]): Pick<Result, keyof Source>;
287+
315288
/**
316289
* Returns an array of all symbol properties found directly on object o.
317290
* @param o Object to retrieve the symbols from.

0 commit comments

Comments
 (0)