There was a discussion on this awhile back on reddit,
see https://www.reddit.com/r/elm/comments/5q4nji/closest_elm_architecture_in_js/
My personal favorite and I believe closest to Elm (0.16) is outlined here:
https://github.com/paldepind/functional-frontend-architecture
On Saturday, February 2
Thank you! Very informative and laugh-out-loud funny! Really helpful,
thanks! - Bob
On Sat, Feb 25, 2017 at 7:27 PM, Witold Szczerba
wrote:
> Hi,
> so you want to carry The Elm Architecture (TEA) to the "vanilla JS" world.
> I came across recently an article: "How I converted my React app to
>
Thanks for this discussion, these kinds of modelling decisions I feel like
I struggle with over and over. And inevitably I get something not quite
right and then later have a massive cleanup to do since everything else
depends on the shape of the model :(
I like your step by step procedure Rup
Hi,
so you want to carry The Elm Architecture (TEA) to the "vanilla JS" world.
I came across recently an article: "How I converted my React app to
VanillaJS". React is quite similar to TEA, actually it's React/Redux that
is similar, but still, I think you could find something useful there.
https://
Greetings. I'm an OCaml guy, teaching Web Apps for the first time and
finding my way through the insanity that is HTML + CSS + JS and trying to
impart something sensible to students for how to structure their vanilla JS
apps to conform to the the Elm Architecture (model-view-update). First time
That worked!!
Good to know!! I will do that next time.
Thank you!
--
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.
Fo
Hi,
that would be so much easier to help you if you would have prepared an
executable using runelm.io or ellie-app.com.
Taking a quick look at your update function I would suggest:
InputEmail email ->
{ model | email = StringField email (validateEmail email) }
! []
Regards,
Wi
Thanks for the quick reply!!
I'm not sure I'm following that. I'm trying that code and it does not know
what the "emailModel" and "passwordModel" are.
Cannot find variable `emailModel`
52| ( { model | email = { emailModel | value = email, errors =
validateEmail email } }, Cmd.none )
I think what you're looking for is this syntax:
( { model | email = { emailModel | value = email, errors = validateEmail
email } }, Cmd.none )
and
( { model | password = { passwordModel | value = password, errors =
validatePassword password } }, Cmd.none )
On Sat, Feb 25, 2017 at 2:08 PM, Micha
Hello, new to elm and experimenting around with it and I'm not sure how to
update a sub model. I have not run across an example of this form yet.
Given the following:
-- MODEL
type alias StringField =
{
value : String
, errors : List String
}
--> how to update value and erro
I use Elm 0.18.
I have written the following, simple Elm program. It is supposed to
accumulate values, sent from JS. I'd also like to get the accumulated
value from the program, back to JS.
port module App exposing (..)
import Json.Decode
import Task
-- model
ty
I've also been using elm on the server side, and have some thoughts:
In elm-0.18 you'll use a Platform.program or Platform.programWithFlags and
pass command line arguments via the flags from a small javascript runner.
Unlike Sonny Michaud's approach, I've used the normal
init/update/subscripti
Aha, that's promising
I have my own starter https://github.com/simonh1000/elm-hot-loading-starter
and have tried https://github.com/halfzebra/create-elm-app and both
experienced the issues I described. I will take a look at what you do
Simon
On Saturday, 25 February 2017 18:13:09 UTC+1, Austin
This isn't really a "solution" to your problem, but because I had endless
frustrating headaches with elm-webpack-starter I switched to the much
simpler elm-live:
https://github.com/tomekwi/elm-live
and create-elm-app:
https://github.com/halfzebra/create-elm-app/blob/master/template/README.md
Is this with elm-webpack-loader, or some other package? I use
elm-webpack-loader and the webpack-dev-server, and it definitely recovers
after a broken compilation. You can see my configuration here if that
helps: https://github.com/abingham/accu-2017-elm-app
On Saturday, February 25, 2017 at 4:
I have tried webpack directly and some of the starters, but I can't find a
way to use hotloading after making a change that led to a compiler error.
It only works if you write perfect code and recompile. If you have an
error, then when these have been fixed the page reloads with the default
sta
I just did this exercise too! My solution was to perform the validation
from the update function and to save the error messages in the model.
On Saturday, 25 February 2017 06:55:06 UTC, Anurup Mitra wrote:
>
> Dear Alex,
>
> This is very elegant indeed! I am bowled over by the simplicity of it a
One trick I have learned when integrating date range picker is that you can
push data from component to Elm using custom HTML events instead of sending
data through a port(s).
I have described it shortly here:
https://www.reddit.com/r/elm/comments/5uqa13/those_fancy_date_pickers_in_elm_watch_this_n
18 matches
Mail list logo