Created
July 10, 2015 06:11
-
-
Save jergason/4e49d78e9b39aee507bb to your computer and use it in GitHub Desktop.
i am the best at elm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Html exposing (h1, div, text) | |
import Mouse | |
renderMouse : (Int, Int) -> Html.Html | |
renderMouse pos = | |
div [] [ | |
h1 [] [text ("x" ++ (toString (fst pos)))], | |
h1 [] [text ("y" ++ (toString (snd pos)))] | |
] | |
main : Signal Html.Html | |
main = Signal.map renderMouse Mouse.position |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment