Re: [elm-discuss] Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread James Hamilton
That is a fair point, actually. I think the idea of aliasing the functions on 0.18 might be a good temporary measure which would allow the community to get used to the new function names without breaking any code and then the old ones can be removed in a later version. On Tuesday, October 25,

[elm-discuss] Re: zip function in the standard library

2016-10-26 Thread 'Andrew Radford' via Elm Discuss
I Had that reaction at first also, however I don't mind so much now cause you do see map2 appear in other core packages (e.g Task), so the change must be for consistency. Much as I dislike function names with numbers in them like 'map2', 'zip' doesn't work well everywhere. In other words, it

Re: [elm-discuss] why no more primes on 0.18 ?

2016-10-26 Thread 'Andrew Radford' via Elm Discuss
Yeah comparing underscore length seems inferior to counting back ticks.. Maybe that was the idea? to discourage the use of double/triple primes etc and steer people to a more point free style? The 0.18 migration guidance does not mention anything like that though On Sunday, 23 October 2016 18:

[elm-discuss] RSS Feed for Elm Packages

2016-10-26 Thread Zachary Kessin
Just a random thought, might it be interesting to have a RSS Feed from the elm package library. Something to show new packages and updates etc. I figure it would be nice to have a way to know what is new and interesting in the community Zach -- Zach Kessin SquareTarget

[elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread 'Rupert Smith' via Elm Discuss
On Thursday, October 20, 2016 at 3:12:57 PM UTC+1, Robin Heggelund Hansen wrote: > > In the same spirit, I propose that we change the name of foldl to > foldLeft, and the name of foldr to foldRight. The difference between foldl > and foldr isn't to spot at a cursory glance. foldLeft is also more

Re: [elm-discuss] why no more primes on 0.18 ?

2016-10-26 Thread Wouter In t Velt
The primes I currently use mostly in msg' and in model' in update functions. It will take some getting used to, but not too bad I guess. I agree that newModel or similar is easier to read, so probably an improvement. The backticks like in `andThen` I won't miss. It is probably more consistent a

Re: [elm-discuss] why no more primes on 0.18 ?

2016-10-26 Thread Wouter In t Velt
Never mind my question: type' will be type_ -- 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 http

Re: [elm-discuss] tictactoe game with elm (newbie)

2016-10-26 Thread Did
I was thinking of a solution like yours after my previous mail. I ended up with something more or less similar to your solution. And then, I went to this solution : filterRow: Int -> List Box -> Maybe Box filterRow boxId row = row |> List.filter (\box -> box.id == boxId && not (box.player ==

Re: [elm-discuss] RSS Feed for Elm Packages

2016-10-26 Thread Peter Damoc
Alternatively, the part that creates the http://package.elm-lang.org/all-packages json could also pull the timestamps from the github tags and the package list view could use that to allow for sorting the packaged by the tag date. On Wed, Oct 26, 2016 at 1:52 PM, Zachary Kessin wrote: > Just a

Re: [elm-discuss] why no more primes on 0.18 ?

2016-10-26 Thread 'Andrew Radford' via Elm Discuss
Yeah but it does beg the question whether type'' should become type__ and of course suggesting a possible hell scenario when this goes further: type__, type___, type ?! Or, is that considered a code smell anyway so it should not be catered for? On Wednesday, 26 October 2016 12:29:10 UTC+

Re: [elm-discuss] tictactoe game with elm (newbie)

2016-10-26 Thread Peter Damoc
On Wed, Oct 26, 2016 at 2:36 PM, Did wrote: > But It seems that, in the update function, currentBox always return > something because it doesn't update my model... I'm obviously doing > something wrong. But, for me, as all cells are unoccupied, this test should > return Nothing. What's wrong ? >

Re: [elm-discuss] tictactoe game with elm (newbie)

2016-10-26 Thread Did
Thanks again Peter for your time and your precious help! I really want to learn, and it's nearly impossible alone... Le mercredi 26 octobre 2016 14:01:48 UTC+2, Peter Damoc a écrit : > > > > On Wed, Oct 26, 2016 at 2:36 PM, Did > > wrote: > >> But It seems that, in the update function, currentBo

Re: [elm-discuss] tictactoe game with elm (newbie)

2016-10-26 Thread Wouter In t Velt
Op woensdag 26 oktober 2016 13:36:18 UTC+2 schreef Did: > > But It seems that, in the update function, currentBox always return > something because it doesn't update my model... I'm obviously doing > something wrong. But, for me, as all cells are unoccupied, this test should > return Nothing. Wh

Re: [elm-discuss] why no more primes on 0.18 ?

2016-10-26 Thread Wouter In t Velt
Op woensdag 26 oktober 2016 13:51:03 UTC+2 schreef Andrew Radford: > > Yeah but it does beg the question whether > > type'' > > should become type__ > The type' variable was in the 0.17 Html.Attributes package. I don't think double primes are an issue there. For other variables, that we define,

[elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread Wouter In t Velt
Op woensdag 26 oktober 2016 13:21:03 UTC+2 schreef Rupert Smith: > > Also worth pointing out that these libraries (and possibly others) have > adopted the convention of using a single 'l' or 'r' to mean from-the-left > and from-the-right: > And the List library also has a scanl function (no sca

Re: [elm-discuss] tictactoe game with elm (newbie)

2016-10-26 Thread Peter Damoc
On Wed, Oct 26, 2016 at 3:04 PM, Did wrote: > Thanks again Peter for your time and your precious help! I really want to > learn, and it's nearly impossible alone... > You're never alone. :) Have you joined the Slack channels? There is almost always someone in #beginners , #help or #general that

[elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread Robin Heggelund Hansen
I think aliasing would just push the problem further into the future. At some point breakage would have to happen, there's no reason to not having it being done right now. It's not like your code base will be any smaller when the aliasing is removed. True, the change should be reflected in simi

[elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread Max Goldstein
Evan has said that the best time to make breaking changes is right now. He's also said that he likes to batch changes, so they're easier for him to work on and make more sense when adopted as a community. For example, flipping andThen and removing backticks go together. -- You received this me

[elm-discuss] Re: Is there any way to use a type instead of a string for the value of an option

2016-10-26 Thread Martin Cerny
I think this points to a more general use case. I think it would be useful to be able to use union types a bit like enums in other languages (my background is mostly Java). For example having type Role = Admin | Moderator | User it would be cool to get something like: Role.optionNames == [

[elm-discuss] Re: Is there any way to use a type instead of a string for the value of an option

2016-10-26 Thread OvermindDL1
That sounds like a typeclass or a HPT, neither of which are in Elm (yet?). Passing in manual serialization/deserialization functions is easy to do though. :-) On Wednesday, October 26, 2016 at 10:32:18 AM UTC-6, Martin Cerny wrote: > > I think this points to a more general use case. I think it

[elm-discuss] Internationalized date/time support

2016-10-26 Thread Jeremy Shute
I need internationalization support for Date/Time, per the instructions in the package I'm mailing this mailing list, though it's with a PR. I wrote https://github.com/shutej/rfc3339/blob/master/src/Native/Rfc3339.js an eon ago to solve this, but the change was rejected. Here's another crack at t

Re: [elm-discuss] Re: zip function in the standard library

2016-10-26 Thread Nick H
It's not the *standard* library, but this function and a ton of other List stuff is available in elm-community/list-extra On Tue, Oct 25, 2016 at 11:07 AM, wrote: > I agree with Luis and Gulshan. Having a "zip" function without a

[elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread Mike MacDonald
Aliases could also remain forever, so people could choose which they prefer. However, this seems counter to the prevailing direction for Elm. On Wednesday, October 26, 2016 at 9:42:25 AM UTC-4, Robin Heggelund Hansen wrote: > > I think aliasing would just push the problem further into the futur

Re: [elm-discuss] Re: Proposal: rename foldl til foldLeft and foldr to foldRight

2016-10-26 Thread Joey Eremondi
Yeah, aliases make easy to write, but harder to read and learn, since a user might have only ever seen one and might not know what the other does. On Wed, Oct 26, 2016 at 11:42 AM, Mike MacDonald wrote: > Aliases could also remain forever, so people could choose which they > prefer. However, th

Re: [elm-discuss] Re: Metalinguistic abstractions over databases

2016-10-26 Thread 'Rupert Smith' via Elm Discuss
On Tuesday, October 25, 2016 at 3:12:53 PM UTC+1, Kasey Speakman wrote: > > So to phrase what I previously said a different way, a database is the > wrong level of abstraction to be shooting for. > Yes, I think you are right. Much better if we can just think about the data model we need, and h

[elm-discuss] Re: RSS Feed for Elm Packages

2016-10-26 Thread gilesb
I think that's a great idea. Currently I think a few different people on Twitter are sort of doing this manually. Speaking of which, if the feed happens, an RSS -> Twitter bot might be good too. On Wednesday, October 26, 2016 at 4:52:55 AM UTC-6, Zachary Kessin wrote: > > Just a random thought,

Re: [elm-discuss] Re: RSS Feed for Elm Packages

2016-10-26 Thread Zachary Kessin
The RSS to twitter bot could be put toether in about an hour on Zapier, I would be happy to do it, I was thinking about starting a feature on my blog http://get-finch.com called "Elm package of the week" Zach ᐧ On Wed, Oct 26, 2016 at 6:50 PM, wrote: > I think that's a great idea. Currently I t