Created
December 12, 2015 05:48
-
-
Save localshred/2362267e7939baf4e700 to your computer and use it in GitHub Desktop.
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
module Foo where | |
-- ... | |
type Action = | |
MetaKeyDown Bool | |
-- ... |
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
module Main where | |
import Keyboard | |
import Foo | |
import Bar | |
type Action = | |
FooEvent Foo.Action | |
| BarEvent Bar.Action | |
type alias Model = | |
{ fooModel : Foo.Model | |
, barModel : Bar.Model | |
} | |
main : Signal Html | |
main = | |
app.html | |
app : StartApp.App Model | |
app = | |
StartApp.start { init = init | |
, update = update | |
, view = view | |
, inputs = inputs | |
} | |
inputs : List (Signal Action) | |
inputs = | |
[ Signal.map (FooEvent Foo.MetaKeyDown) Keyboard.meta -- this is clearly wrong as Foo.MetaKeyDown is not a reference I can make | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment