Module

FRP.Event.Keyboard

Package
purescript-hyrule
Repository
mikesol/purescript-hyrule

#Keyboard Source

newtype Keyboard

A handle for creating events from the keyboard.

#getKeyboard Source

getKeyboard :: Effect Keyboard

Get a handle for working with the keyboard.

#down Source

down :: Event String

Create an Event which fires when a key is pressed

#up Source

up :: Event String

Create an Event which fires when a key is released

#withKeys Source

withKeys :: forall a. Keyboard -> Event a -> Event { keys :: Set String, value :: a }

Create an event which also returns the currently pressed keys.