workspace
stringclasses 4
values | channel
stringclasses 4
values | text
stringlengths 1
3.93k
| ts
stringlengths 26
26
| user
stringlengths 2
11
|
---|---|---|---|---|
elmlang | general | Then you could react on it in the client requesting a token | 2019-02-26T09:22:58.272900 | Lynne |
elmlang | general | Yes, I do. I was thinking of something along those lines. | 2019-02-26T09:23:14.273100 | Karma |
elmlang | general | Thank you for your help :slightly_smiling_face: | 2019-02-26T09:23:26.273300 | Karma |
elmlang | general | Welcome :slightly_smiling_face: | 2019-02-26T09:23:32.273500 | Lynne |
elmlang | general | Do you have recommendations on how to handle dropdowns?
If I see it correctly there are currently three packages for 0.19 that provide such functionality. Hence I wondered, if these are what anyone is using OR if everyone is rolling their own OR if most are simply using the standard html `<select>` | 2019-02-26T09:34:16.279900 | Moshe |
elmlang | general | Use the standard HTML `<select>` unless you have a good reason to do something else | 2019-02-26T09:35:26.280400 | Carman |
elmlang | general | I suspect “the designer does not like it” is not a sufficiently good reason, right? :smile: | 2019-02-26T09:36:31.281000 | Moshe |
elmlang | general | depending on the supported browsers, the datalist could work | 2019-02-26T09:38:33.282000 | Iona |
elmlang | general | <https://www.w3schools.com/tags/tag_datalist.asp> | 2019-02-26T09:38:48.282600 | Iona |
elmlang | general | Well, I guess that's a conversation you need to have with them. Why do they not like the standard `<select>`? Is it just the look and feel? Is there some extra functionality they want (e.g. searchable)? What about accessibility/keyboard support concerns? | 2019-02-26T09:39:28.283400 | Carman |
elmlang | general | Well the comment was a little tounge in cheek, sorry :wink: Actually the main problem, most of the times, seems to be additional wishes for the look and feel. The typical request I get is “we need an Icon next to this option”, and I can see how this can be problematic when you have strict rules on corporate identity | 2019-02-26T09:43:18.286700 | Moshe |
elmlang | general | A specific icon, or one of the unicode set? | 2019-02-26T09:43:49.287000 | Niesha |
elmlang | general | A specific icon, a specific background color for the overlay. There are different scenarios really | 2019-02-26T09:46:23.288200 | Moshe |
elmlang | general | I have a form that needs to:
• auto-save on blur
• run validations server-side and show errors client-side (but don't prevent saving)
• dynamically add an arbitrary number of child forms
• intersperse form fields with some other markup and display-only values that are not part of the form | 2019-02-26T09:52:44.288600 | Carman |
elmlang | general | What are people's thoughts on <https://package.elm-lang.org/packages/hecrj/composable-form/latest/> for this? I like its approach to building forms but my use-case departs significantly from its defaults. The package provides the ability to add custom fields and behavior although it looks like I may need to do some significant work to meet my needs. | 2019-02-26T09:52:52.288900 | Carman |
elmlang | general | Alternatively, I'm looking at just building my own form from scratch but I'm afraid I may end up duplicating a lot of the customization work I would have done with the package solution above so I'm questioning if it's worth it. Thoughts? :slightly_smiling_face: | 2019-02-26T09:52:56.289100 | Carman |
elmlang | general | It's open source? Clone it into your project and hack it until it fits? | 2019-02-26T09:57:34.292200 | Dede |
elmlang | general | I really liked playing around with composable-form in its default state, also with custom view functions. But building custom fields was really not that simple. iirc there are plans to improve the experience for that. The motivation to play around with the library was to possibly switch away from a different one. My current stand is to build my own form, pulling out functionality on the way. | 2019-02-26T09:58:51.293100 | Jin |
elmlang | general | The package is built to be extensible. My concern is around whether its worth doing the work to extend versus just rolling my own form since my use-case is so different than normal | 2019-02-26T09:59:49.293200 | Carman |
elmlang | general | Hello everybody.
We still need speakers for elm europe
<https://checkout.eventlama.com/#/events/elm-europe-2019/cfp>
if you have something interesting (and diverse) to say, don’t hesitate to apply !
We are especially interested by “real world” feedback
as in :
How is it to do full time elm in an organization
How did you handle complexity in a team where elm is not totally sold to all the team
How do you manage big elm projects
Is agile still necessary in an elm powered company
How did we manage to do … in elm | 2019-02-26T11:29:56.293800 | Valeria |
elmlang | general | I like to keep a request index on the model. Whenever I send a new search, I bump the index on the model and curry that new index onto the response Msg. It looks something like this:
```
Search query ->
({ model | searchRequestIndex = model.searchRequestIndex + 1,
, Api.Search query (SearchResults model.searchRequestIndex + 1)
)
SearchResults requestIndex results ->
if requestIndex /= model.searchRequestIndex then
(model, Cmd.none)
else
( { model | results = results}, Cmd.none)
``` | 2019-02-26T11:30:27.293900 | Lorilee |
elmlang | general | And … one little thing :
we just released an early bird workshop on elm graphql with Dillon Kearns !
<http://2019.elmeurope.org/#tickets> | 2019-02-26T12:15:01.294600 | Valeria |
elmlang | general | Hey! For two of my projects I need a spring-based animation system. I remember there was some talk about it last year, but I couldn't find any package for that. Am I just bad at searching? | 2019-02-26T12:56:56.296700 | Dorsey |
elmlang | general | Yesterday I actually rolled my own and I'm considering publishing it, but if there is a prior work available, then maybe I should not duplicate it. | 2019-02-26T12:58:01.297900 | Dorsey |
elmlang | general | <https://package.elm-lang.org/packages/mdgriffith/elm-style-animation/latest/> | 2019-02-26T13:05:25.298100 | Dede |
elmlang | general | Uses springs internally. | 2019-02-26T13:05:37.298400 | Dede |
elmlang | general | Is it not possible to upgrade a package? I have a project running elm/http at 1.0.0 and I want to upgrade that to 2.0.0. I see no commands for updating when running `elm install --help`. I seem to vaguely remember having upgraded packages in the past… | 2019-02-26T14:02:01.299800 | Salley |
elmlang | general | Manually remove it from elm.json and reinstall it with `elm install` | 2019-02-26T14:04:36.300300 | Dede |
elmlang | general | Then I get ```dev // 19:58:50 🍔 elm install elm/http
Here is my plan:
Add:
elm/http 1.0.0
Would you like me to update your elm.json accordingly? [Y/n]: ``` | 2019-02-26T14:05:12.300600 | Salley |
elmlang | general | is there another package with an explicit dependency on 1.0.0 ? | 2019-02-26T14:06:11.301600 | Hoyt |
elmlang | general | Yes. Try removing `elm/core`. | 2019-02-26T14:06:22.301900 | Dorsey |
elmlang | general | And installing it again. | 2019-02-26T14:06:31.302200 | Dorsey |
elmlang | general | Possibly some other, like `elm/json`. | 2019-02-26T14:06:42.302500 | Dorsey |
elmlang | general | Yeah it seems to be one of my dependencies that are requiring and older version of elm/http. Any way to check which one? | 2019-02-26T14:08:17.303500 | Salley |
elmlang | general | You can also look in the lock file to get a sense | 2019-02-26T14:08:27.303900 | Hoyt |
elmlang | general | This tool is helpful for finding conflicts: <https://github.com/malaire/elm-dependencies-analyzer> | 2019-02-26T14:13:08.304200 | Claretta |
elmlang | general | Ah, turns out it was elm-http-builder that was requiring elm-http version 1 | 2019-02-26T14:13:43.304700 | Salley |
elmlang | general | Is it ok to send multiple cfps? | 2019-02-26T14:28:19.304800 | Bebe |
elmlang | general | To publish a package, do I have to host my source code on GitHub or can I use other git servers? I'm specifically thinking about GitLab. | 2019-02-26T14:54:51.306200 | Dorsey |
elmlang | general | I think it is just GitHub right now | 2019-02-26T14:55:55.306300 | Bebe |
elmlang | general | Are there any up-to-date elm vs react benchmarks? | 2019-02-26T15:47:19.307000 | Kris |
elmlang | general | Yep | 2019-02-26T18:17:53.307400 | Valeria |
elmlang | general | As much as you want | 2019-02-26T18:18:01.307800 | Valeria |
elmlang | general | Please concentrate on pure elm and no js (as much as possible) | 2019-02-26T18:18:59.309000 | Valeria |
elmlang | general | For us was the change in the Error type, it drops important information about errors | 2019-02-26T19:12:23.309300 | Carrol |
elmlang | general | does anyone know what the preferred SVG library for 0.19 is? Since it seems that elm-lang/svg/2.0.0 does not work with 0.19 | 2019-02-26T21:26:16.310200 | Grady |
elmlang | general | <@Grady> <https://package.elm-lang.org/packages/elm/svg/latest/> | 2019-02-26T21:35:53.310500 | Earlean |
elmlang | general | all the `elm-lang/` packages moved to `elm/` in 0.19 | 2019-02-26T21:36:13.311000 | Earlean |
elmlang | general | ah makes sense. thanks <@Earlean>! | 2019-02-26T21:43:55.311600 | Grady |
elmlang | general | That’s nice, thanks | 2019-02-27T01:09:10.314900 | Raymonde |
elmlang | general | I have a built a EnhancedTextarea module that is basically a Html.textarea with some additional functionality. One of them is to do some special processing in Javascript when copying and pasting, for which purpose I have a `Json.Decode.Value -> Cmd msg)` port for sending pasted data out to javascript and a `(Json.Decode.Value -> msg) -> Sub msg` port to get the processed data back. This is all great, except for when I have multiple `EnhancedTextarea`s on one page. After sending data out through the first port, I have no way of deciding which textarea was actually pasted into when the subscription is triggered. I don't want to mess with the Json.Decode.Value too much, because I have to run `event.clipboardData.getData("text/html")` on it on the javascript file (which it seems like I cannot do on the elm side). | 2019-02-27T03:32:19.321000 | Shaina |
elmlang | general | Is there a good way of specifying which of my multiple textareas the pasted data should actually go into? | 2019-02-27T03:32:48.321700 | Shaina |
elmlang | general | Is it possible to turn my ports into `(Json.Decode.Value, TextareaId) -> Cmd msg`, etc. and how would the handling look on the javascript file (I've had a hard time getting tuples in ports to work in the past)? | 2019-02-27T03:33:45.322800 | Shaina |
elmlang | general | You could extract the id of the target on the JS side, or use the tuple solution (which becomes an array on the JS side) | 2019-02-27T03:44:31.324400 | Huong |
elmlang | general | <@Shaina> when I make http calls, I partially apply the return message with an id like:
```
Http.get
{ url = "<https://elm-lang.org/assets/public-opinion.txt>"
, expect = Http.expectString (GotStuff myId)
}
``` | 2019-02-27T03:44:56.324800 | Nana |
elmlang | general | I think you could do the same? | 2019-02-27T03:45:07.325000 | Nana |
elmlang | general | It's a little harder with ports because there's no (direct) correspondence between the "request" and "response" | 2019-02-27T03:46:06.326000 | Huong |
elmlang | general | Exactly. But I think it may be possible to extract the id like you suggested, <@Huong> | 2019-02-27T03:46:33.326700 | Shaina |
elmlang | general | oh you're right, forgot about that :thinking_face: | 2019-02-27T03:46:59.327000 | Nana |
elmlang | general | <@Huong> Using the event.target.id worked beautifully. | 2019-02-27T04:07:27.327600 | Shaina |
elmlang | general | Thanks | 2019-02-27T04:07:32.327800 | Shaina |
elmlang | general | I'm trying to upgrade my project to 0.19, but I used Bogdanp/elm-time package which is not upgraded yet. What are the best alternatives on 0.19? | 2019-02-27T04:51:01.329200 | Selena |
elmlang | general | Have you considered `elm/time`? <https://package.elm-lang.org/packages/elm/time/latest/> | 2019-02-27T04:52:31.329300 | Elza |
elmlang | general | There are also few alternatives mentioned at the fork of `elm-community/elm-time` (which is now deprecated): <https://package.elm-lang.org/packages/isaacseymour/deprecated-time/latest> | 2019-02-27T04:55:45.329700 | Lynne |
elmlang | general | <@Elza> I think we tried it at first but Bogdans package worked better for us, but now I will sure reconsider it. Thank you | 2019-02-27T05:02:56.329900 | Selena |
elmlang | general | <@Lynne> None of the links is working for me :thinking_face: | 2019-02-27T05:03:39.330100 | Selena |
elmlang | general | Not for me either... | 2019-02-27T05:04:24.330300 | Lynne |
elmlang | general | It is weird but if you search by package name you will definitely find them at least on Github | 2019-02-27T05:04:42.330500 | Lynne |
elmlang | general | For example, <https://github.com/justinmimbs/date> | 2019-02-27T05:04:53.330700 | Lynne |
elmlang | general | Thank you, I'll surely check them out | 2019-02-27T05:06:02.330900 | Selena |
elmlang | general | <@Carrol> makes you handle it yourself with ```expectStringResponse``` | 2019-02-27T05:06:21.331100 | Leonore |
elmlang | general | There are many ways that made it difficult for me. No more toTask, changing every request I had since I can't prepare and send them afterwards like how it used to be. And some other things... | 2019-02-27T05:09:14.331300 | Leonore |
elmlang | general | Actually, `Bogdanp/elm-time` is a fork of `elm-community/elm-time`. If you don't want to change how you work with time now, using Isaac's fork can be enough, perhaps. | 2019-02-27T05:25:24.331500 | Lynne |
elmlang | general | Yep I did that and I seems like its ok solution, but I think i will need to find another solution in the future. Thank you. | 2019-02-27T05:27:42.331700 | Selena |
elmlang | general | If you are using Bogdanp/elm-time and you want to upgrade your project to 0.19 this package <https://package.elm-lang.org/packages/isaacseymour/deprecated-time/latest> may be a good temporary solution. | 2019-02-27T05:28:35.332700 | Selena |
elmlang | general | Has anyone implemented GDRP cookie consent logic to enable/disable Google Analytics in an ELM application? | 2019-02-27T05:43:29.333300 | Fonda |
elmlang | general | Good news! <@Kristle> has written a .DOT parser and published as package: <https://github.com/erkal/kite/issues/4#issuecomment-467639803> | 2019-02-27T10:03:00.334000 | Reuben |
elmlang | general | :smile: i still have a few problems to solve! once i figure those out, i'll write some docs and truly publish it to the package manager | 2019-02-27T10:21:58.335100 | Kristle |
elmlang | general | hello everyone!
I have a basic question about `Json.Decode`
I need to decode a field from a `json` that can be a string (`"theValue"`) or a list (`["value_1", "value_1"]`) | 2019-02-27T12:59:07.336900 | Karrie |
elmlang | general | how can I do that? :slightly_smiling_face: | 2019-02-27T12:59:24.337300 | Karrie |
elmlang | general | You'll want to use `Decode.oneOf` | 2019-02-27T13:00:03.337700 | Carman |
elmlang | general | e.g.
```
oneOrMany : Decoder (List String)
oneOrMany =
Decode.oneOf [ singleItem, manyItems ]
singleItem : Decoder (List String)
singleItem =
Decode.map (\str -> [ str ]) Decode.string
manyItems : Decoder (List String)
manyItems =
Decode.list Decode.string
``` | 2019-02-27T13:01:45.339600 | Carman |
elmlang | general | what if the value in elm is just `List (String)` and not `List (String) | String` ? | 2019-02-27T13:02:29.340300 | Karrie |
elmlang | general | That's what the `Decode.map (\str -> [ str ])` part handles | 2019-02-27T13:02:53.340800 | Carman |
elmlang | general | oh yes! :smile: | 2019-02-27T13:03:04.341300 | Karrie |
elmlang | general | if there is a single string, it will wrap it in a list :slightly_smiling_face: | 2019-02-27T13:03:05.341400 | Carman |
elmlang | general | thanks a lot <@Carman>! :slightly_smiling_face: | 2019-02-27T13:03:17.341800 | Karrie |
elmlang | general | Go with less dependencies I guess? | 2019-02-27T13:03:59.342000 | Johna |
elmlang | general | is there a way I can decode the value `1` (Int) to `"1"` (String) ? | 2019-02-27T14:04:05.343000 | Karrie |
elmlang | general | ```
intAsString : Decoder String
intAsString =
Decode.map String.fromInt <http://Decode.int|Decode.int>
``` | 2019-02-27T14:05:05.343800 | Carman |
elmlang | general | You can think of `Decode.map` as a way to apply some post-processing to the value decoded | 2019-02-27T14:05:57.344600 | Carman |
elmlang | general | Or if you want to *only* decode `1` as a string:
```
<http://Decode.int|Decode.int>
|> Decode.andThen (\int -> if int == 1 then Decode.succeed 1 else Decode.fail "wrong number" )
|> Decode.map String.fromInt
``` | 2019-02-27T14:07:48.346400 | Kris |
elmlang | general | You can collapse the `map` inside the `andThen`, but it's the same | 2019-02-27T14:08:22.346600 | Kris |
elmlang | general | love you! | 2019-02-27T14:11:22.347000 | Karrie |
elmlang | general | hahah | 2019-02-27T14:11:32.347200 | Karrie |
elmlang | general | On json decode found that this afternoon <https://github.com/zwilias/elm-demystify-decoders> | 2019-02-27T15:31:03.349600 | Gabriele |
elmlang | general | Anyone here know of or have any opinions or company conventions on when to track the state of a page via the URL? It’s sort of along the lines of the problem domain of SPA’s & SEO but more about linkability.
I’m trying to put together an Elm talk for my company with a tongue in cheek title “Using Elm to solve all your problems” or “I got `undefined is not a function` problems but Elm ain’t one!”
My coworker was interested if there was a convention for “tracking resource/object state” via the url so links would take you to the correct state in a SPA. | 2019-02-27T15:33:24.352200 | Buffy |
elmlang | general | we do some of this | 2019-02-27T15:38:12.352400 | Simon |
elmlang | general | (just beginning)_ | 2019-02-27T15:38:16.352600 | Simon |
elmlang | general | in general changing page state by way of URL is “most correct” (in b2b case at least) - because people like to open in new windows etc | 2019-02-27T15:38:37.353100 | Simon |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.