puppeteer/website/versioned_docs/version-20.8.3/api/puppeteer.locator.on.md
release-please[bot] 6be24edacc
chore: release main (#10570)
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
2023-07-18 12:40:13 +02:00

714 B

sidebar_label
Locator.on

Locator.on() method

Signature:

class Locator {
  on<K extends keyof LocatorEventObject>(
    eventName: K,
    handler: (event: LocatorEventObject[K]) => void
  ): this;
}

Parameters

Parameter Type Description
eventName K
handler (event: LocatorEventObject[K]) => void

Returns:

this