elm-community / html-extra

Additional functions for working with Html.
http://package.elm-lang.org/packages/elm-community/html-extra/latest
MIT License
31 stars 14 forks source link

Add Html.Extra.maybe #21

Closed Janiczek closed 5 years ago

Janiczek commented 5 years ago

This has been useful for us, as we littered our codebase with case maybe of ... Nothing -> Html.nothing and Maybe.unwrap Html.nothing ... :smile:

Janiczek commented 5 years ago

I guess we can raise the question - should it be named viewMaybe, given there already is viewIf?

prikhi commented 5 years ago

Hmm, well viewIf is necessary because if is a keyword. It'd be nice if that could just be used like Html.if but I suppose we should keep the naming standardized so if you want to push that change, I'll merge and make a new release.

prikhi commented 5 years ago

Thanks! Merged & pushed a new version.