fromEvent
Creates an Observable that emits events of a specific type coming from the given event target.
Last updated
Was this helpful?
Creates an Observable that emits events of a specific type coming from the given event target.
Last updated
Was this helpful?
Parameters
target
The DOM EventTarget, Node.js EventEmitter, JQuery-like event target, NodeList or HTMLCollection to attach the event handler to.
eventName
The event name of interest, being emitted by the target
.
options
Optional. Default is undefined
.
Options to pass through to addEventListener
resultSelector
Optional. Default is undefined
.
Type: (...args: any[]) => T
.