Module

Pha.App

Package
purescript-pha
Repository
gbagan/purescript-pha

#app Source

app :: forall msg state effs. { init :: Tuple state (Action state effs), subscriptions :: state -> Array (Sub msg), update :: msg -> Action state effs, view :: state -> Document msg } -> App msg state effs (aff :: AFF | effs)

#sandbox Source

sandbox :: forall msg state. { init :: state, update :: msg -> state -> state, view :: state -> VDom msg } -> App msg state () (aff :: AFF)
sandbox ∷ ∀msg state effs. {
    init ∷ state,
    view ∷ state → VDom msg,
    update ∷ msg → state → state,
    node ∷ String
} → Effect Unit

#addInterpret Source

addInterpret :: forall msg state effs effs1 effs2. Interpret state effs1 effs2 -> App msg state effs effs1 -> App msg state effs effs2

#attachTo Source

attachTo :: forall msg state effs. String -> App msg state effs (aff :: AFF) -> Effect Unit

#Document Source

type Document msg = { body :: VDom msg, title :: String }

#App Source

newtype App msg state effs neffs