Event

Event returns a new event whose type attribute value is set to type. The eventInitDict argument allows for setting the bubbles, cancelable, and composed attributes via object members of the same name.

Syntax

event = new Event(type [, eventInitDict])

Parameters

type

The type of event.

eventInitDict

Allows setting the bubbles, cancelable, and composed attributes.

Examples

1

2

3

4

5

6

Internal

bubbles

cancelable

composed

composedPath

currentTarget

defaultPrevented

eventPhase

isTrusted

preventDefault

stopImmediatePropagation

stopPropagation

target

timeStamp

type

External

Web Hypertext Application Technology Working Group (WHATWG)

Home Menu