Skinney/keyboard-events - version: 2.0.1

for more information visit the package's GitHub page

Package contains the following modules:

Keyboard Events

This package extends ohanhi/keyboard with functions that produce Html events that fire messages when a given key is pressed. It works as follows:

import Html exposing (Html, input)
import Keyboard exposing (Key(..))
import Keyboard.Events as Keyboard


type Msg =
    CloseAutoComplete


autocomplete : Html Msg
autocomplete =
    input
        [ Keyboard.on Keyboard.Keydown [(Escape, CloseAutoComplete) ]]
        []

Licence

This package uses the BSD-3 licence.