Skip to content

Commit eabee0a

Browse files
committed
Use correct array type for Object.keys
1 parent a685ac4 commit eabee0a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/es5.d.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ interface ObjectConstructor {
238238
* Returns the names of the enumerable string properties and methods of an object.
239239
* @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.
240240
*/
241-
keys(o: object): string[];
241+
keys<T extends object>(o: T): Array<Extract<keyof T, string>>;
242242
}
243243

244244
/**

0 commit comments

Comments
 (0)