lue-bird / elm-review-pattern / Review.Pattern.As

Forbid ... as ..variable.. patterns.

forbid : Review.Rule.Rule

Forbid ... as ..variable.. patterns.

config =
    [ Review.Pattern.As.forbid
    ]

For example

view ({ windowSize } as model) =
    Html.text "Hello!"

will be fixed to

view model =
    let
        { windowSize } =
            model
    in
    Html.text "Hello!"

This fix doesn't try to merge this destructuring into existing lets. Adding jfmengels/elm-review-simplify will do this for you.

why