Liking cljdoc? Tell your friends :D

str-helpers

Few helper functions for Clojure strings.

Usage

(use 'str-helpers)

dasherize - Turns underscores and whitespaces into dashes.

(dasherize "hello world")  ; => "hello-world"
(dasherize "hello_world")  ; => "hello-world"

underscore - Turns dashes and whitespaces into underscores.

(underscore "hello-world") ; => "hello_world"
(underscore "hello world") ; => "hello_world"

humanize - Capitalizes the first word and turns underscores and dashes into spaces.

(humanize "hello-world")   ; => "Hello world"
(humanize "hello_world")   ; => "Hello world"

License

Copyright (C) 2012 edtsech

Distributed under the Eclipse Public License, the same as Clojure.

Can you improve this documentation?Edit on GitHub

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close