elm-community / elm-faq

FAQ about the Elm language.

Home Page:https://faq.elm-community.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Point to elm-update-extra package?

jvoigtlaender opened this issue · comments

At http://elm-community.github.io/elm-faq/17.html#how-do-i-generate-a-new-message-as-a-command, there is this comment:

Sending a new message this way is often not necessary. The same effect can often be had by calling the update function recursively with the new message.

It might be helpful to point the reader to http://package.elm-lang.org/packages/ccapndave/elm-update-extra/latest/Update-Extra here, which has convenience functions and examples for doing this in different kinds of cases (e.g., when there are several messages to deal with in that way, like in this thread on the mailing list).

I added a link to the Update-Extra package as you suggested.

(This very thing was helpful in addressing a question on Slack today.)