No, Html.Html is not related to Program. That Html.Html is permitted as type of main is special-cased “magic”. It’s useful, for example, to give SSCCE <http://sscce.org/>s when writing bug reports.
2016-07-24 7:58 GMT+02:00 Duane Johnson <[email protected]>: > I was working through Elm in Action (first 2 chapters) today and I > realized I don't understand how `main` can be of type `Html.Html`: > > main = >> div [ class "content" ] [ text "Photo Groove" ] > > > In the documentation for `Platform > <http://package.elm-lang.org/packages/elm-lang/core/4.0.3/Platform#Program>` > it says: > > Every Elm project will define main to be some sort of `Program`. > > > Is `Html.Html` a kind of `Program`? Is there some kind of magic going on > here? Thanks! > > Duane > > -- > 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. > -- 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.
