Skip to content

Instantly share code, notes, and snippets.

@mjs2600
Last active August 29, 2015 14:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mjs2600/00c479b2064f54cc80ed to your computer and use it in GitHub Desktop.
Save mjs2600/00c479b2064f54cc80ed to your computer and use it in GitHub Desktop.
My first Elm program. It looks sort of like my Elixir.
import Mouse
import Text
main : Signal Element
main = [constant "Hello, World! ",
lift show Mouse.position]
|> combine
|> lift display
display : [String] -> Element
display elements = elements
|> map format
|> flow right
format : String -> Element
format content = content
|> toText
|> Text.color blue
|> centered
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment