AddEventListenerOptions

data class AddEventListenerOptions(val signal: AbortSignal? = null, val passive: Boolean = false, val once: Boolean = false, val capture: Boolean = false)

Node: Add Listener Options

Options which can be passed to the target.addEventListener method.

Constructors

Link copied to clipboard
constructor(signal: AbortSignal? = null, passive: Boolean = false, once: Boolean = false, capture: Boolean = false)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val capture: Boolean = false

If true, the listener is invoked when the event is dispatched in the capture phase.

Link copied to clipboard
val once: Boolean = false

If true, the listener is removed after the next time a type event is dispatched.

Link copied to clipboard
val passive: Boolean = false

When true, serves as a hint that the listener will not call the Event object's preventDefault() method. Default: false.

Link copied to clipboard
val signal: AbortSignal? = null

Can be used to cancel waiting for the event.