Module

React.Basic.DOM.Events

Package
purescript-react-basic
Repository
lumihq/purescript-react-basic

This module defines safe DOM event function and property accessors.

#capture Source

capture :: forall a. EventFn SyntheticEvent a -> (a -> Effect Unit) -> EventHandler

Create a capturing* EventHandler to send an action when an event occurs. For more complicated event handlers requiring Effect, use handler from React.Basic.Events.

*calls preventDefault and stopPropagation

See also: update, capture_, monitor, React.Basic.Events

#capture_ Source

capture_ :: Effect Unit -> EventHandler

Like capture, but for actions which don't need to extract information from the Event.

See also: update, capture, monitor_

#bubbles Source

bubbles :: EventFn SyntheticEvent Boolean

General event fields

#eventPhaseNone Source

#eventPhaseCapturing Source

#eventPhaseAtTarget Source

#eventPhaseBubbling Source

#key Source

key :: EventFn SyntheticEvent (Maybe String)

Keyboard event fields

#detail Source

detail :: EventFn SyntheticEvent (Maybe Int)

Mouse event fields