view : Model -> Html Msg
view model =
let
ratingViewConfig =
{ Rating.defaultViewConfig | readOnly = model.readOnly }
in
div []
[ Html.map SetRatingState <|
Rating.view ratingViewConfig model.ratingState
, label []
[ input
[ type_ "checkbox"
, checked model.readOnly
, onClick ToggleReadOnly
]
[]
, text "read only"
]
]
I ran into something unexpected when parsing your code!
63| { Rating.defaultViewConfig | readOnly = model.readOnly }
^
I am looking for one of the following things:
a closing bracket '}'
a lower case name
whitespace
let
defaultViewConfig = Rating.defaultViewConfig
ratingViewConfig =
{ defaultViewConfig | readOnly = model.readOnly }
in
...
However, if I update the let bindings as follows:let
defaultViewConfig = Rating.defaultViewConfig
ratingViewConfig =
{ defaultViewConfig | readOnly = model.readOnly }
in
...Then, there is no error. Am I missing something or is this a bug in the parser?