Debug.log
's second argument is always returned, so you could write code like the following and it would just work:
update : Msg -> Model -> (Model, Cmd Msg)
update msg model =
case Debug.log "The Message" msg of
Something ->
...
Replacing case msg of
with case Debug.log "The Message" msg of
will cause the current message to be logged the console every time the update function is called, but changes nothing else.