I figured out what my problem was

I was swallowing the command message

 update : Msg -> Model -> ( Model, Cmd Msg )
   update msg model =
  case msg of 
    JsInterop action ->
          ( { model | jsInterop = fst (JsInterop.State.update action 
model.jsInterop) }
           , Cmd.none
)


I fixed it doing this using Cmd.map


update : Msg -> Model -> ( Model, Cmd Msg )
update msg model =
    case msg of
        JsInterop action ->
            let
                updateobj =
                    (JsInterop.State.update action model.jsInterop)
            in
                ( { model | jsInterop = fst updateobj }
                , Cmd.map JsInterop (snd updateobj)
                )

Is there a cleaner way to do this?

Thanks

-- 
You received this message because you are subscribed to the Google Groups "Elm 
Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to