Fix lib typings with errors

This commit is contained in:
Nuckyz 2025-02-16 22:57:05 -03:00
parent 1f67203183
commit 1f0635ffc8
No known key found for this signature in database
GPG key ID: 440BF8296E1C4AD9
6 changed files with 14 additions and 18 deletions

View file

@ -131,7 +131,7 @@ function shouldIgnoreValue(value: any) {
return false;
}
function makePropertyNonEnumerable(target: Object, key: PropertyKey) {
function makePropertyNonEnumerable(target: Record<PropertyKey, any>, key: PropertyKey) {
const descriptor = Object.getOwnPropertyDescriptor(target, key);
if (descriptor == null) return;
@ -499,7 +499,7 @@ export function findExportedComponentLazy<T extends object = any>(...props: Prop
});
}
function getAllPropertyNames(object: Object, includeNonEnumerable: boolean) {
function getAllPropertyNames(object: Record<PropertyKey, any>, includeNonEnumerable: boolean) {
const names = new Set<PropertyKey>();
const getKeys = includeNonEnumerable ? Object.getOwnPropertyNames : Object.keys;