2020-06-04 14:56:45 +00:00
|
|
|
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
|
|
|
|
|
|
[Home](./index.md) > [puppeteer](./puppeteer.md) > [Frame](./puppeteer.frame.md) > [$eval](./puppeteer.frame._eval.md)
|
|
|
|
|
|
|
|
## Frame.$eval() method
|
|
|
|
|
|
|
|
<b>Signature:</b>
|
|
|
|
|
|
|
|
```typescript
|
2020-07-02 09:09:34 +00:00
|
|
|
$eval<ReturnType>(selector: string, pageFunction: (element: Element, ...args: unknown[]) => ReturnType | Promise<ReturnType>, ...args: SerializableOrJSHandle[]): Promise<WrapElementHandle<ReturnType>>;
|
2020-06-04 14:56:45 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
|
|
|
| Parameter | Type | Description |
|
|
|
|
| --- | --- | --- |
|
|
|
|
| selector | string | |
|
2020-07-02 09:09:34 +00:00
|
|
|
| pageFunction | (element: Element, ...args: unknown\[\]) => ReturnType \| Promise<ReturnType> | |
|
2020-06-25 12:38:01 +00:00
|
|
|
| args | [SerializableOrJSHandle](./puppeteer.serializableorjshandle.md)<!-- -->\[\] | |
|
2020-06-04 14:56:45 +00:00
|
|
|
|
|
|
|
<b>Returns:</b>
|
|
|
|
|
2020-07-02 09:09:34 +00:00
|
|
|
Promise<[WrapElementHandle](./puppeteer.wrapelementhandle.md)<!-- --><ReturnType>>
|
2020-06-04 14:56:45 +00:00
|
|
|
|