Skip to content

Minor Bug Fix #16

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 23 additions & 28 deletions docs/diff/es2015.core.d.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,14 +126,13 @@ Index: es2015.core.d.ts
/**
* The value of the largest integer n such that n and n + 1 are both exactly representable as
* a Number value.
@@ -273,45 +282,26 @@
@@ -273,49 +282,20 @@
/**
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
- * @param source The source object from which to copy properties.
+ * @param sources One or more source objects from which to copy properties
*/
- */
- assign<T, U>(target: T, source: U): T & U;
-
- /**
Expand All @@ -154,39 +153,35 @@ Index: es2015.core.d.ts
- * @param source3 The third source object from which to copy properties.
- */
- assign<T, U, V, W>(
+ assign<T, Ts extends readonly any[]>(
target: T,
- target: T,
- source1: U,
- source2: V,
- source3: W
- ): T & U & V & W;
+ ...sources: Ts
+ ): CheckNonNullable<
+ T,
+ First<
+ UnionToIntersection<
+ | [T]
+ | {
+ [K in keyof Ts]: [Ts[K]];
+ }[number]
+ >
+ >
+ >;

/**
-
- /**
- * Copy the values of all of the enumerable own properties from one or more source objects to a
- * target object. Returns the target object.
- * @param target The target object to copy to.
- * @param sources One or more source objects from which to copy properties
- */
* @param sources One or more source objects from which to copy properties
*/
- assign(target: object, ...sources: any[]): any;
-
- /**
+ assign<T, Ts extends readonly any[]>(
+ target: CheckNonNullable<T>,
+ ...sources: Ts
+ ): Intersect<[T, ...Ts]>;

/**
* Returns an array of all symbol properties found directly on object o.
* @param o Object to retrieve the symbols from.
*/
getOwnPropertySymbols(o: any): symbol[];
@@ -326,16 +316,23 @@
- getOwnPropertySymbols(o: any): symbol[];
+ getOwnPropertySymbols<T>(o: CheckNonNullable<T>): symbol[];

/**
* Returns the names of the enumerable string properties and methods of an object.
* @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.
@@ -326,16 +306,23 @@
* Returns true if the values are the same value, false otherwise.
* @param value1 The first value.
* @param value2 The second value.
Expand All @@ -212,7 +207,7 @@ Index: es2015.core.d.ts

interface ReadonlyArray<T> {
/**
@@ -346,20 +343,25 @@
@@ -346,20 +333,25 @@
* immediately returns that element value. Otherwise, find returns undefined.
* @param thisArg If provided, it will be used as the this value for each invocation of
* predicate. If it is not provided, undefined is used instead.
Expand Down Expand Up @@ -249,7 +244,7 @@ Index: es2015.core.d.ts

/**
* Returns the index of the first element in the array where predicate is true, and -1
@@ -369,11 +371,11 @@
@@ -369,11 +361,11 @@
* findIndex immediately returns that element index. Otherwise, findIndex returns -1.
* @param thisArg If provided, it will be used as the this value for each invocation of
* predicate. If it is not provided, undefined is used instead.
Expand All @@ -264,7 +259,7 @@ Index: es2015.core.d.ts
}

interface RegExp {
@@ -433,26 +435,17 @@
@@ -433,26 +425,17 @@
* same as the corresponding elements of this object (converted to a String) starting at
* endPosition – length(this). Otherwise returns false.
*/
Expand Down
20 changes: 8 additions & 12 deletions docs/diff/es2017.object.d.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Index: es2017.object.d.ts
===================================================================
--- es2017.object.d.ts
+++ es2017.object.d.ts
@@ -2,34 +2,45 @@
@@ -2,34 +2,42 @@
/**
* Returns an array of values of the enumerable properties of an object
* @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.
Expand All @@ -23,7 +23,7 @@ Index: es2017.object.d.ts
+ * Returns an array of values of the enumerable properties of an object
+ * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.
+ */
+ values<T>(o: T): CheckNonNullable<T, unknown[]>;
+ values<T>(o: CheckNonNullable<T>): unknown[];

/**
* Returns an array of key/values of the enumerable properties of an object
Expand All @@ -42,7 +42,7 @@ Index: es2017.object.d.ts
+ * Returns an array of key/values of the enumerable properties of an object
+ * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.
+ */
+ entries<T>(o: T): CheckNonNullable<T, [string, unknown][]>;
+ entries<T>(o: CheckNonNullable<T>): [string, unknown][];

/**
* Returns an object containing all own property descriptors of an object
Expand All @@ -52,15 +52,11 @@ Index: es2017.object.d.ts
- o: T
- ): { [P in keyof T]: TypedPropertyDescriptor<T[P]> } & {
- [x: string]: PropertyDescriptor;
- };
+ getOwnPropertyDescriptors<T>(o: T): CheckNonNullable<
+ T,
+ {
+ [P in keyof T]: TypedPropertyDescriptor<T[P]>;
+ } & {
+ [x: string]: PropertyDescriptor;
+ }
+ >;
+ getOwnPropertyDescriptors<T>(o: CheckNonNullable<T>): {
+ [P in keyof T]: TypedPropertyDescriptor<T[P]>;
+ } & {
+ [x: PropertyKey]: PropertyDescriptor;
};
}

```
Loading