Hi, I am quite often doing the same thing (plus exposing the main type having the same name than the module) like:
import Module.Something as Something exposing (Something) What I am concerned about is that it would be implicit, and all implicit things tend to lead to confusion. On Sunday, November 20, 2016 at 2:51:42 PM UTC+8, Robin Heggelund Hansen wrote: > > Note. The `as` keyword would still be necessary for brevity is desired, > and for when two modules are imported where the last part of the name is > the same. > > søndag 20. november 2016 07.50.42 UTC+1 skrev Robin Heggelund Hansen > følgende: >> >> I mostly try to use qualified imports instead of exposing variables into >> my namespace. This leads me to using the `as` keyword often, like this: >> >> ``` >> import Module.B as B >> import Module.C as C >> {- etc. -} >> ``` >> >> In Go, accessing a namespace through the last part of it's name, is >> implicit. If that was true of Elm as well, the example above would be the >> same as: >> >> ``` >> import Module.B >> import Module.C >> {- etc. -} >> ``` >> >> For me, having this in Elm would remove most of my uses of the `as` >> keyword. If my other import proposal was also implemented, import handling >> would be simpler, at least for me, without sacrificing readability. >> >> What do people think? >> > -- 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 elm-discuss+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.