jfmengels / elm-review-simplify

Provides elm-review rules to simplify your Elm code
https://package.elm-lang.org/packages/jfmengels/elm-review-simplify/latest/
BSD 3-Clause "New" or "Revised" License
20 stars 9 forks source link

Add Array.toList simplifications #234

Closed lue-bird closed 9 months ago

lue-bird commented 9 months ago

Add Array.toList simplifications listed in #174

Array.toList Array.empty
--> []

Array.toList (Array.repeat n a)
--> List.repeat n a

including composition

Luckily, I was able to re-use an existing helper for the repeat.

github-actions[bot] commented 9 months ago

The branch can be tried out by running:

elm-review --template jfmengels/elm-review-simplify/preview