2022-07-05 13:41:43 +00:00
|
|
|
---
|
|
|
|
sidebar_label: JSHandle.asElement
|
|
|
|
---
|
|
|
|
|
|
|
|
# JSHandle.asElement() method
|
|
|
|
|
2022-10-24 07:07:05 +00:00
|
|
|
#### Signature:
|
2022-07-05 13:41:43 +00:00
|
|
|
|
|
|
|
```typescript
|
|
|
|
class JSHandle {
|
2022-07-06 07:05:37 +00:00
|
|
|
asElement(): ElementHandle<Node> | null;
|
2022-07-05 13:41:43 +00:00
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
**Returns:**
|
|
|
|
|
2022-07-06 07:05:37 +00:00
|
|
|
[ElementHandle](./puppeteer.elementhandle.md)<Node> \| null
|
2022-07-05 13:41:43 +00:00
|
|
|
|
2022-08-11 09:45:35 +00:00
|
|
|
Either `null` or the handle itself if the handle is an instance of [ElementHandle](./puppeteer.elementhandle.md).
|