Module

Marionette.Types

Package
purescript-marionette
Repository
thought2/purescript-marionette

This module contains types that are only needed for low level Renderer/Controller implementations.

#Controller Source

newtype Controller msg sta

A controller is defined as a computation that runs in Aff when given an implementation to send messages, a low level State implementation along with the current a messsage that has been triggered.

Constructors

Instances

#Renderer Source

newtype Renderer msg sta

Type variables:

  • msg message type of your program
  • sta state type of your program

Record fields:

  • onInit runs before the state machine starts
  • onState runs on every state update
  • onFinish runs before the state machine exits

Constructors

Instances

#SendMsg Source

type SendMsg :: Type -> (Type -> Type) -> Typetype SendMsg msg m = msg -> m Unit

Defines how messages can be triggered by the runtime

#State Source

newtype State :: Type -> (Type -> Type) -> Typenewtype State s m

Low level state implementation that allows to derive reading and updating state functions

Constructors