Skip to main content

Page.$$eval() method

Signature:

class Page {
$$eval<
Params extends unknown[],
Func extends EvaluateFunc<[Element[], ...Params]> = EvaluateFunc<
[Element[], ...Params]
>
>(
selector: string,
pageFunction: Func | string,
...args: Params
): Promise<Awaited<ReturnType<Func>>>;
}

Parameters

ParameterTypeDescription
selectorstring
pageFunctionFunc | string
argsParams

Returns:

Promise<Awaited<ReturnType<Func>>>