re: Writing A Word Memory Game In Elm - Part 2: Modeling And Building a Basic Word Memory Game VIEW POST

VIEW FULL DISCUSSION
 

viewSentence takes one argument:

viewSentence : Words -> Html msg
viewSentence sentence =

But in the view you are passing two arguments:

view : Model -> Html msg
view model =
    main_ [ class "section" ]
        [ div [ class "container" ]
            [ viewTitle
            , div [ class "box" ]
                [ p
                    [ class "has-text-centered" ]
                    [ text model.sentence ]
                , viewSentence model.chosenSentence model.chosenWords
                ]
            ]
        ]
 

Hi, Anton.

You are absolutely right! I was trying to code along with the writing, but still got some things wrong.

Just updated the article and added Ellie links.

Thank you.

code of conduct - report abuse