For a better interface though is there a way you could just go over the list and see if there is an Html.class attribute in it and just append your new values to it (or prepend whichever)? That would get rid of the specialized types in the front-end while allowing you to mix and merge as you need in pre-processing?
On Friday, July 22, 2016 at 9:06:46 AM UTC-6, debois wrote: > > I am curious as to why attributes of elm-mdl things are different from >> normal attributes, doing things like `Option.cs` compared to `Html.class` >> is just an odd discrepancy when I thought it might be possible just to use >> both elm-mdl specific things as well as normal ones (perhaps via a Union >> type?) >> > > Precisely because elm-mdl needs to set certain classes on elements, but so > does the user. We can't let the user supply `class`, because elm-mdl cannot > subsequently add to that. Internally, `cs` and friends are actually > implemented > > <https://github.com/debois/elm-mdl/blob/master/src/Material/Options.elm#L173-L177>using > constructors > of a union type > <https://github.com/debois/elm-mdl/blob/master/src/Material/Options/Internal.elm> > . > -- 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.
