(blank? s)
True is s is nil, empty, or contains only whitespace.
True is s is nil, empty, or contains only whitespace.
(capitalize s)
Converts first character of the string to upper-case, all other characters to lower-case.
Converts first character of the string to upper-case, all other characters to lower-case.
(escape s cmap)
Return a new string, using cmap to escape each character ch from s as follows:
If (cmap ch) is nil, append ch to the new string. If (cmap ch) is non-nil, append (str (cmap ch)) instead.
Return a new string, using cmap to escape each character ch from s as follows: If (cmap ch) is nil, append ch to the new string. If (cmap ch) is non-nil, append (str (cmap ch)) instead.
(join coll)
(join separator coll)
Returns a string of all elements in coll, as returned by (seq coll), separated by an optional separator.
Returns a string of all elements in coll, as returned by (seq coll), separated by an optional separator.
(lower-case s)
Converts string to all lower-case.
Converts string to all lower-case.
(replace s match replacement)
Replaces all instance of match with replacement in s. match/replacement can be:
string / string pattern / (string or function of match).
Replaces all instance of match with replacement in s. match/replacement can be: string / string pattern / (string or function of match).
(replace-first s match replacement)
Replaces the first instance of match with replacement in s. match/replacement can be:
string / string pattern / (string or function of match).
Replaces the first instance of match with replacement in s. match/replacement can be: string / string pattern / (string or function of match).
(reverse s)
Returns s with its characters reversed.
Returns s with its characters reversed.
(split s re)
(split s re limit)
Splits string on a regular expression. Optional argument limit is the maximum number of splits. Not lazy. Returns vector of the splits.
Splits string on a regular expression. Optional argument limit is the maximum number of splits. Not lazy. Returns vector of the splits.
(trim s)
Removes whitespace from both ends of string.
Removes whitespace from both ends of string.
(trim-newline s)
Removes all trailing newline \n or return \r characters from string. Similar to Perl's chomp.
Removes all trailing newline \n or return \r characters from string. Similar to Perl's chomp.
(triml s)
Removes whitespace from the left side of string.
Removes whitespace from the left side of string.
(trimr s)
Removes whitespace from the right side of string.
Removes whitespace from the right side of string.
(upper-case s)
Converts string to all upper-case.
Converts string to all upper-case.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close