Skip to main content
Version: 23.9.0

JSHandle.getProperty() method

getProperty(): Promise<HandleFor<T[K]>>

Fetches a single property from the referenced object.

Signature

class JSHandle {
getProperty<K extends keyof T>(
propertyName: HandleOr<K>,
): Promise<HandleFor<T[K]>>;
}

Parameters

Parameter

Type

Description

propertyName

HandleOr<K>

Returns:

Promise<HandleFor<T[K]>>

getProperty(): Promise<JSHandle<unknown>>

Signature

class JSHandle {
getProperty(propertyName: string): Promise<JSHandle<unknown>>;
}

Parameters

Parameter

Type

Description

propertyName

string

Returns:

Promise<JSHandle<unknown>>