2023-06-02 17:46:10 +00:00
|
|
|
---
|
|
|
|
sidebar_label: Locator.click
|
|
|
|
---
|
|
|
|
|
|
|
|
# Locator.click() method
|
|
|
|
|
|
|
|
#### Signature:
|
|
|
|
|
|
|
|
```typescript
|
|
|
|
class Locator {
|
2023-07-25 10:43:07 +00:00
|
|
|
click<ElementType extends Element>(
|
2023-07-19 15:39:38 +00:00
|
|
|
this: Locator<ElementType>,
|
|
|
|
options?: Readonly<LocatorClickOptions>
|
2023-06-02 17:46:10 +00:00
|
|
|
): Promise<void>;
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
2023-07-19 15:39:38 +00:00
|
|
|
| Parameter | Type | Description |
|
|
|
|
| --------- | ------------------------------------------------------------------------- | ------------ |
|
|
|
|
| this | [Locator](./puppeteer.locator.md)<ElementType> | |
|
|
|
|
| options | Readonly<[LocatorClickOptions](./puppeteer.locatorclickoptions.md)> | _(Optional)_ |
|
2023-06-02 17:46:10 +00:00
|
|
|
|
|
|
|
**Returns:**
|
|
|
|
|
|
|
|
Promise<void>
|