Skip to main content
Version: 20.8.2

Locator.on() method

Signature:

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

Parameters

ParameterTypeDescription
eventNameK
handler(event: LocatorEventObject[K]) => void

Returns:

this