summaryrefslogtreecommitdiff
blob: 08c2540794a24b6fdb83e129c7f3050a317c5544 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
module ElmModule.Init exposing (init)

-- Local Module ----------------------------------------------------------------
import Struct.Flags
import Struct.Event
import Struct.Model

import Comm.LoadStory

--------------------------------------------------------------------------------
-- LOCAL -----------------------------------------------------------------------
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
-- EXPORTED --------------------------------------------------------------------
--------------------------------------------------------------------------------
init : Struct.Flags.Type -> (Struct.Model.Type, (Cmd Struct.Event.Type))
init flags =
   -- TODO: read flags and request story.
   ((Struct.Model.new), (Comm.LoadStory.request "/story/0.json"))