SyntheticEvent class

A cross-browser wrapper around the browser's nativeEvent.

It has the same interface as the browser's native event, including stopPropagation and preventDefault, except the events work identically across all browsers.

See: reactjs.org/docs/events.html#syntheticevent

Implementers
Available Extensions
Annotations
  • @JS()

Properties

bubbles bool
Indicates whether the Event bubbles up through the DOM or not.
no setter
cancelable bool
Indicates whether the Event is cancelable or not.
no setter
currentTarget → dynamic
Identifies the current target for the event, as the Event traverses the DOM.
no setter
defaultPrevented bool
Indicates whether or not preventDefault was called on the event.
no setter
eventPhase num
Indicates which phase of the Event flow is currently being evaluated.
no setter
hashCode int
The hash code for this object.
no setterinherited
isTrusted bool
Is true when the Event was generated by a user action, and false when the Event was created or modified by a script or dispatched via EventTarget.dispatchEvent.
no setter
nativeEvent → dynamic
The native browser event this wraps.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stopPropagation → dynamic
Prevents further propagation of the current event.
no setter
target → dynamic
A reference to the object that dispatched the event. It is different from currentTarget when the Event handler is called when eventPhase is Event.BUBBLING_PHASE or Event.CAPTURING_PHASE.
no setter
timeStamp num
Returns the time (in milliseconds) at which the Event was created.
no setter
type String
Returns a string containing the type of event. It is set when the Event is constructed and is the name commonly used to refer to the specific event.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
preventDefault() → void
Cancels the Event if it is cancelable, without stopping further propagation of the event.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited