macchiato-framework / macchiato-fs

ClojureScript wrapper for Node filesystem API
MIT License
21 stars 5 forks source link

Discussion: remove slurpy keyword args #5

Closed jjl closed 7 years ago

jjl commented 7 years ago

I just took at peek at the macchiato.fs namespace and I see a lot of slurpy keyword args. These are more difficult to wrap than functions which just take an optional params map.

A recent discussion on clojure IRC led to a general concensus that slurpy keyword args were in general a code smell. I vote to change them to take an optional extra options map. Thoughts?

yogthos commented 7 years ago

The main reason for that was to keep consistent with Clojure slurp that uses keyword args.

jjl commented 7 years ago

Ah yes, that's true, I hadn't noticed it was just for spit and slurp.

Hrm, doing it right or copying clojure? Tough call...