hendore/elm-port-message/1.0.2

NOTE: this package is not compatible with Elm 0.19.1

PortMessage

Useful functions for building a PortMessage to be delivered through ports.

type alias PortMessage =
{ tag : Tag
, payload : Value
}

Builder

new : Tag -> PortMessage

Create a new PortMessage with an empty payload.

withPayload : Value -> PortMessage -> PortMessage

Attach a payload to the PortMessage