Here's my take.
In C++ (Or Java, what-have-you), you could have something like this:
class Square {
private float size;
Square(float size) {
this.size = size;
}
void size(float size) {
this.size = size;
}
float size(void) {
return this.size;
}
float
If you control the sender and are guaranteed to get some messages exceeding
the websocket limit (which I'm assuming is 4500 bytes) is to either send
multiple smaller updates, or assign some sort of message id and prepend it
to each chunk.
Another option you can do (if you can't control the
Also to expand on why I used an empty tuple - Elm, from my understanding,
will cache the call if it just returns a Bool, because it ends up looking
like a constant. I don't know if, as a result, Elm will actually execute
the function a second time, or if it will just return the boolean value
Is there a good reason *not* to use a port for this? The difficultly level
is very low, and t's a single js function call.
Also, don't even consider a native module at all. The general consensus is
that native code isn't meant for the general Elm population, because it has
the ability to
upert Smith' via Elm Discuss" <
elm-discuss@googlegroups.com> wrote:
On Saturday, February 18, 2017 at 11:23:01 PM UTC, Alex Barry wrote:
>
> I think for integer division, it has to return 0 because infinity is
> expressed as a float. I'm going to agree with Erkal, though, yo
I think for integer division, it has to return 0 because infinity is
expressed as a float. I'm going to agree with Erkal, though, you definitely
don't want to wrap all your math statements in a maybe or result type, that
would make most code considerably more verbose.
On Sat, Feb 18, 2017 at 5:38
Type Msg
= ...
| NoOp msg
update msg model =
case msg of
NoOp _ -> ( model, Cmd.none )
That should do the trick for you. You might want a better message name.
Also, why discard the message?
On Fri, Jan 27, 2017 at 10:45 AM, 'Rupert Smith' via Elm Discuss <
Just to pipe in with my experience, I'm working on a medium sized project
with a lot of inter-related data between my modules, which is dictated by a
database structure. We started the project as a single file elm project,
but the code was starting to get unmanageable, so we broke it out into