I've posted a full example here:
https://gist.github.com/artisonian/4f62ee4572a788d5d801c997e5a560ce
If it'd be helpful, I can work on a writeup to explain my design choices.
On Friday, December 2, 2016 at 8:11:45 PM UTC-5, Nima Birgani wrote:
>
> Hi all,
>
> I'm trying to decode an relatively
I think I have something close to what you're looking for, but my solution
makes me wonder, *why store text in your model rather than the parsed
float/int values?* It seems like you want the parsed values for a
calculation, not to format a paragraph of text.
update : Msg -> Model -> Model
gt; calling window.close, the current port implementation would have worked for
> me.
>
> On Oct 17, 2016 2:03 PM, "Leroy Campbell" <artis...@gmail.com
> > wrote:
>
>> From what I can tell, port communication uses Cmd because interop with
>> JavaScript isn'
>From what I can tell, port communication uses Cmd because interop with
JavaScript isn't necessarily a request-response communication pattern
(instead, port are pubsub).
But I do have a question: *Is the underlying problem a need to coordinate
access to a shared resource in JavaScript? *I ask
Rather than decode to nested Dict types, you could create types that represent
your domain better (assuming the underlying JSON is well-structured). You can
also use `andThen` to decode based on some field in your objects.
--
You received this message because you are subscribed to the Google
Mark,
I don't understand why so much concern about private state. The reason
components (in JS frameworks) need private state is to protect them from
accidental mutation by callers. With immutable data, I don't see a need to hide
data.
I've had to maintain several 10K+ JavaScript codebases.
I'd say learning how to make illegal states unrepresentable.
https://vimeo.com/162036084
--
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
Just to clarify, inbound messages to Elm are batched (enqueued) and then
executed on nextTick.
And to echo Luke, observables would make more sense. A Promise-based
interface would mean supporting only request-response semantics.
Observables not only allow for request-response, but also
It may help to watch this talk on modeling from a functional programming
perspective (features F#, but applicable to Elm since they both are
ML-based):
https://vimeo.com/162036084
On Sunday, July 17, 2016 at 7:06:32 PM UTC-4, Leonardo Sá wrote:
>
> Short question:
>
> What is the best way to
I recreated your example without issue, so I wonder if there is another
problem. Here's a fork of your gist:
https://gist.github.com/artisonian/11e93321cd7fd108142115269cbeafe7
On Monday, July 18, 2016 at 4:40:06 AM UTC-4, Zachary Kessin wrote:
>
> I am having a strange problem with ports, I am
I assume if it were possible to have lists with mixed types, you'd lose
some algebraic guarantees. How would you use such a list? There's probably
another way to accomplish the same thing while retaining type safety.
On Friday, May 20, 2016 at 1:41:38 PM UTC-4, John Orford wrote:
>
> Why isn't
11 matches
Mail list logo