clj-commons / camel-snake-kebab

A Clojure[Script] library for word case conversions
https://clj-commons.org/camel-snake-kebab/
Eclipse Public License 1.0
475 stars 49 forks source link

performance improvements needed #1

Closed boxxxie closed 11 years ago

boxxxie commented 11 years ago

i am using this to convert camel case json to clojure kabab case keywords... i have found that this conversion is extremely slow!

please offer memoized versions in this lib. :)

qerub commented 11 years ago

You can easily memoize the functions yourself with clojure.core.memoize so I see no point in offering it built-in.

In regard to performance, I'd happily accept concrete advice or patches unless they sacrifice code readability.

qerub commented 11 years ago

By the way, com.google.common.base.CaseFormat is a more performant alternative.

qerub commented 11 years ago

I added some notes about memoization to the README: https://github.com/qerub/camel-snake-kebab/tree/master#with-memoization