Welcome! Please see the About page for a little more info on how this works.

0 votes
in ClojureScript by
edited by

I'm dealing with JSON data that always uses snake case. While it is possible to achieve what I want with clojure.walk, I think it would be convenient to add an option to js->clj to not only keywordize keys, but also demunge them, so that "some_key" becomes :some-key.

1 Answer

0 votes
by

Wouldn't it be more flexible if keywordize-keys received a function instead of a boolean, so you can do whatever you want, including demunging?

by
I think that's a good idea, too, but it may break existing code, so I decided to suggest adding an extra option.
...