workspace
stringclasses
4 values
channel
stringclasses
4 values
text
stringlengths
1
3.93k
ts
stringlengths
26
26
user
stringlengths
2
11
elmlang
general
Definitely a bug in the grammar
2019-05-11T00:13:28.356800
Kris
elmlang
general
Hey everyone, I posted this on elm-discuss also but I thought I'd share it here too. I explored what would happen if we thought of components as relational data and came up with a nice way to create reusable components. A great example when this would be useful is if you have an advanced form component or a sortable ta...
2019-05-11T03:29:12.362500
Ashlee
elmlang
general
Sounds like less work to just generate the json decoders instead.
2019-05-11T03:34:29.362600
Niesha
elmlang
general
My advice is to comment here with relevant production code: <https://github.com/elm/compiler/issues/1773>
2019-05-11T08:58:53.364600
Hoa
elmlang
general
Easiest way to save all of package.elm-lang for offline viewing?
2019-05-11T10:16:17.365400
Danika
elmlang
general
Hardcore version? `wget --mirror --convert-links --adjust-extension --page-requisites --no-parent`
2019-05-11T10:27:05.366000
Niesha
elmlang
general
put this in your browser console :wink: `addEventListener("keydown", console.log)`
2019-05-11T10:49:31.366100
Nana
elmlang
general
hmmm :thinking_face:
2019-05-11T10:53:25.367100
Danika
elmlang
general
All the docs get pulled from their respective github repos don't they :confused:
2019-05-11T10:58:56.368000
Danika
elmlang
general
Thanks
2019-05-11T11:31:43.368100
Vallie
elmlang
general
I currently only pass the session to all submodels, but I guess will do the same as you.. I spent a lot of time debugging the current 30 lines of js, so it will be better not to make its code base larger..
2019-05-11T11:54:09.368300
Allison
elmlang
general
<@Danika> There is <https://github.com/drathier/elm-offline>, though I have not used it. And the docs are served from the package website, not GitHub. You can inspect the requests the Elm package website does.
2019-05-11T12:45:34.371400
Jin
elmlang
general
Oh amazing, thanks!
2019-05-11T14:34:39.371700
Danika
elmlang
general
Having a HUGE issue here... Elm just crashed a bunch of our servers
2019-05-11T21:36:04.373600
Emil
elmlang
general
need help ASAP
2019-05-11T21:36:15.374100
Emil
elmlang
general
CIO breathing down my neck
2019-05-11T21:36:26.374400
Emil
elmlang
general
That sounds unlikely to me. How did it crash the servers?
2019-05-11T21:38:20.375500
Wendell
elmlang
general
hold on, I'll get you the error
2019-05-11T21:38:53.376100
Emil
elmlang
general
None
2019-05-11T21:44:00.376300
Emil
elmlang
general
can someone help?
2019-05-11T21:48:20.376700
Emil
elmlang
general
Sounds like Game of Thrones spoilers to me :rolling_on_the_floor_laughing:
2019-05-11T21:48:53.377100
Wenona
elmlang
general
None
2019-05-11T22:00:23.377200
Emil
elmlang
general
None
2019-05-11T22:00:36.377500
Emil
elmlang
general
None
2019-05-11T22:00:49.377800
Emil
elmlang
general
None
2019-05-11T22:01:49.378100
Emil
elmlang
general
None
2019-05-11T22:02:00.378400
Emil
elmlang
general
None
2019-05-11T22:02:11.378700
Emil
elmlang
general
None
2019-05-11T22:02:30.379000
Emil
elmlang
general
None
2019-05-11T22:02:46.379300
Emil
elmlang
general
None
2019-05-11T22:02:55.379600
Emil
elmlang
general
None
2019-05-11T22:03:05.379900
Emil
elmlang
general
None
2019-05-11T22:03:12.380200
Emil
elmlang
general
None
2019-05-11T22:03:19.380500
Emil
elmlang
general
None
2019-05-11T22:03:35.380800
Emil
elmlang
general
None
2019-05-11T22:03:44.381100
Emil
elmlang
general
None
2019-05-11T22:03:58.381400
Emil
elmlang
general
None
2019-05-11T22:04:05.381700
Emil
elmlang
general
None
2019-05-11T22:04:15.382000
Emil
elmlang
general
None
2019-05-11T22:04:24.382300
Emil
elmlang
general
None
2019-05-11T22:04:36.382600
Emil
elmlang
general
None
2019-05-11T22:04:46.382900
Emil
elmlang
general
None
2019-05-11T22:05:07.383200
Emil
elmlang
general
None
2019-05-11T22:05:32.383500
Emil
elmlang
general
None
2019-05-11T22:05:45.383800
Emil
elmlang
general
None
2019-05-11T22:05:56.384100
Emil
elmlang
general
None
2019-05-11T22:06:13.384400
Emil
elmlang
general
None
2019-05-11T22:06:28.384700
Emil
elmlang
general
None
2019-05-11T22:06:40.385000
Emil
elmlang
general
None
2019-05-11T22:06:50.385300
Emil
elmlang
general
None
2019-05-11T22:07:04.385600
Emil
elmlang
general
None
2019-05-11T22:07:32.385900
Emil
elmlang
general
None
2019-05-11T22:07:36.386200
Emil
elmlang
general
Wtf
2019-05-11T23:38:57.386800
Kris
elmlang
general
Very committed spammer.
2019-05-11T23:39:18.387100
Dede
elmlang
general
But way unclear as to why.
2019-05-11T23:39:47.387300
Dede
elmlang
general
oooooook.. on another note, i’m trying to user parcel for bundeling, and it was very easy to set up at first but now i’m realising that it does not seem to get my image references in elm-ui. does anyone have any experience with this and maybe an elegant solution? i could just copy the assets folder after the fact, but ...
2019-05-12T01:31:33.391200
Daryl
elmlang
general
Where is the report button?
2019-05-12T02:27:53.391600
Rebekah
elmlang
general
<@Daryl> copying static assets is a different concern. You can use one of parcel’s static assets plugins. `parcel-plugin-static-files-copy` should be enough for most cases.
2019-05-12T05:46:50.400500
Maida
elmlang
general
You can also use `parcel-plugin-copy` if the above one doesn’t work for you. (I had to use this one in one of my phoenix projects because phoenix is not playing nicely with root js/css.)
2019-05-12T05:49:00.402000
Maida
elmlang
general
ok nice, thank you!
2019-05-12T10:06:27.402400
Daryl
elmlang
general
Hi guys is there somebody using elm and graphql? How good is the support/your satisfaction? I'm newbie regarding elm and its ecosystem (currently ReactJS and graphql-yoga with Prisma on BE) ... elm caught my eye due to one possible contract.
2019-05-12T11:11:00.404800
Melaine
elmlang
general
<@Melaine> there is this package <https://package.elm-lang.org/packages/dillonkearns/elm-graphql/latest> and its creator <@Sade> is pretty active here
2019-05-12T11:12:56.406700
Virgie
elmlang
general
thanks! will check it out
2019-05-12T11:13:39.407400
Melaine
elmlang
general
Hello <@Melaine>! Yes, check it out, and come say hello/get help in <#C0RSQNQ92|graphql> :slightly_smiling_face: There are a lot of people using elm and graphql in production. And a lot of friendly folks willing to answer questions in there!
2019-05-12T11:14:19.408500
Sade
elmlang
general
<@Sade> neat, glad to read that!
2019-05-12T11:15:00.409100
Melaine
elmlang
general
``` { "type": "application", "source-directories": [ "./src/elm", "./elm-pack/composable-form/src" ], "elm-version": "0.19.0", "dependencies": { "direct": { "Chadtech/elm-us-state-abbreviations": "2.0.2", "NoRedInk/elm-json-decode-pipeline": "1.0.0", ...
2019-05-12T11:18:48.409200
Evonne
elmlang
general
Errors are few similar to this: ``` I cannot find a `Http` import. These names seem close though: Decode.Error Char.Char Time.Zone Decoder ```
2019-05-12T11:19:48.409500
Evonne
elmlang
general
<@Alicia> Thanks for your suggestion, I have rewritten the algorithm to use the built-in foldr (tail optimized) function, removing any stack overflow exceptions, thanks again :slightly_smiling_face:
2019-05-12T12:45:02.410900
Amiee
elmlang
general
I know about `onWithOptions`, but how can I prevent default inside an `onKeyDown` subscription when a specific key goes down? Let's say I want to disable a particular key or key combination anywhere on the page.
2019-05-12T15:44:10.412700
Maxwell
elmlang
general
I really just want to know if there's a way to prevent default on a subscription in Elm as I described; an alternative would be fine too, but the goal is to prevent default.
2019-05-12T15:49:16.413000
Maxwell
elmlang
general
I just found out about `onBubble`, which seems like what I need, but it seems that it didn't make it to Elm after all? I'm not sure. <https://github.com/elm-lang/virtual-dom/blob/dev/src/VirtualDom.elm#L230-L244>
2019-05-12T15:57:51.414000
Maxwell
elmlang
general
I'm looking for feedback on <https://gist.github.com/miniBill/cf1698087a9dacaf7c49c60d972ecdf2> The one thing I know for sure is that I need to document it
2019-05-13T02:19:20.415500
Raylene
elmlang
general
It's an implementation of the Encoder/Decoder pair idea. Things that it does and most others don't are ADTs and recursion
2019-05-13T02:20:43.416900
Raylene
elmlang
general
Could you provide an example of this being used? I think that would help me understand what's going on
2019-05-13T02:24:13.417000
Jae
elmlang
general
For example, what would the code look like for creating an encoder pair for { x : Int, y : Int }
2019-05-13T02:25:58.417200
Jae
elmlang
general
And since you said it handles recursion what would the code look like for Tree a = Subtree (Tree a) | Leaf a
2019-05-13T02:30:23.417400
Jae
elmlang
general
Updated the gist with an example
2019-05-13T04:27:46.417800
Raylene
elmlang
general
:thumbsup:
2019-05-13T04:31:01.418000
Jae
elmlang
general
What do you think of the ADT api?
2019-05-13T04:38:12.418200
Raylene
elmlang
general
Encoding records is straight forward. I'm still trying to understand how encoding recursive types works though. What does "cata" mean?
2019-05-13T04:43:29.418400
Jae
elmlang
general
(and by encoding I mean both encoding and decoding)
2019-05-13T04:43:50.418600
Jae
elmlang
general
cata is a wrong name (will fix) for a generic pattern match function
2019-05-13T04:45:48.418800
Raylene
elmlang
general
Another thing, "meta" to me at least, doesn't seem like a good name for a library that combines json encoders and decoders. What about using the term "json codec" instead?
2019-05-13T04:46:59.419000
Jae
elmlang
general
And it's part of the ADT encoding, the recursive part is just the call to `recursive`
2019-05-13T04:47:28.419200
Raylene
elmlang
general
So if I understand correctly, the cata portion of the example describes how to encode the tree, while the alternative1 functions at the end describe how to decode it?
2019-05-13T04:50:13.419400
Jae
elmlang
general
Codec is a good name, thanks, will probably use it
2019-05-13T04:50:39.419700
Raylene
elmlang
general
Exactly!
2019-05-13T04:50:48.419900
Raylene
elmlang
general
And the parameter to buildAdt is needed to have a default value which is needed for the permissive decoder
2019-05-13T04:51:19.420100
Raylene
elmlang
general
If you remove permissiveDecoder you can remove default too
2019-05-13T04:51:42.420300
Raylene
elmlang
general
What does the permissive decoder do?
2019-05-13T04:52:02.420500
Jae
elmlang
general
But it can be useful if, for example, you use this to serialize the model
2019-05-13T04:52:07.420700
Raylene
elmlang
general
It's a decoder that returns a default value instead of erring out. Main difference between that and using Result.withDefault is that it can perform a partial parse so if you pass {x:5} to the Point decoder you will get (5,0) instead of (0,0)
2019-05-13T04:53:53.420900
Raylene
elmlang
general
Of course if you pass "hello" you will get (0,0)
2019-05-13T04:54:35.421100
Raylene
elmlang
general
So if you don't provide a permissive decoder then you'll get Err result like what happens in Json.Decode?
2019-05-13T04:55:10.421300
Jae
elmlang
general
Yeah, if you use Meta.decoder it errs out, permissiveDecoder uses the default
2019-05-13T04:56:47.421500
Raylene
elmlang
general
Alright. I'm a bit pressed for time now but possibly later today I'll try this out with a data structure I have and see how well it goes
2019-05-13T04:57:41.421700
Jae
elmlang
general
Thanks :pray:
2019-05-13T04:58:15.422000
Raylene
elmlang
general
Also I stumbled upon this <https://package.elm-lang.org/packages/prozacchiwawa/elm-json-codec/latest/JsonCodec>, I'm not sure how similar it is to your approach but you might be interested in seeing how they did it.
2019-05-13T05:00:04.422200
Jae
elmlang
general
Oh, it's quite similar
2019-05-13T05:08:56.422400
Raylene
elmlang
general
Hi, how do I import the operate := from Json.Decode?
2019-05-13T06:36:29.423100
John