cuerdas.core

(source)

For more info about this library see:

https://funcool.github.io/cuerdas/latest/
Public Variable Short Description
<< (clj) A backward compatibility alias for `istr` macro.
<<- (clj) Unindent multiline text.
alnum? (clj) Checks if a string contains only alphanumeric characters.
alpha? (clj) Checks if a string contains only alpha characters.
blank? (clj) Checks if is a nil, empty string or contains only whitespace.
camel (clj) Output will be: lowerUpperUpperNoSpaces accepts strings and keywords.
capital (clj) Uppercases the first character of a string.
chars (clj) Split a string in a seq of chars.
clean (clj) Trim and replace multiple spaces with a single space.
collapse-whitespace (clj) Converts all adjacent whitespace characters to a single space.
concat (clj) A macro variant of the clojure.core/str function that performs considerably faster string concatenation operation on CLJS (on JVM/CLJ it only applies basic simplification and then relies on the `clojure.core/str`).
css-selector (clj) Output will be either: (js-selector "LeadingDash") ;; => -leading-dash (js-selector "noLeadingDash") ;; => no-leading-dash accepts keywords and strings, with any standard delimiter.
digits? (clj) Checks if a string contains only digit characters.
empty-or-nil? (clj) Convenient helper for check emptines or if value is nil DEPRECATED: this is already covered by `empty?`.
empty? (clj) Checks if a string is empty.
ends-with? (clj) Check if the string ends with suffix.
escape-html (clj)
ffmt (clj) Alternative (to `istr`) string formating macro, that performs simple string formating on the compile time (this means that the string should be known at compile time).
fmt (clj) A shorter alias to `format` function.
format (clj) Simple string interpolation.
human (clj) Output will be: lower cased and space separated accepts strings and keywords.
includes? (clj) Determines whether a string contains a substring.
index-of (clj)
istr (clj) A string formating macro that works LIKE ES6 template literals but using clojure construcs and symbols for interpolation delimiters.
join (clj) Joins strings together with given separator.
js-selector (clj) Output will be either: (js-selector "-pascal-case-me") ;; => PascalCaseMe (js-selector "camel-case-me") ;; => camelCaseMe accepts keywords and strings, with any standard delimiter.
kebab (clj) Output will be: lower-cased-and-separated-with-dashes accepts strings and keywords.
keyword (clj) Safer version of clojure keyword, accepting a symbol for the namespace and kebab-casing the key.
last-index-of (clj)
letters? (clj) Checks if string contains only letters.
lines (clj) Return a list of the lines in the string.
lower (clj) Converts string to all lower-case.
lstrip (clj)
ltrim (clj) Removes whitespace or specified characters from left side of string.
nilv (clj) Mark a expression string safe, if value is nil or undefined, the "" is returned.
numeric? (clj) Check if a string contains only numeric values.
one-of? (clj) Returns true if s can be found in coll.
pad (clj) Pads the str with characters until the total string length is equal to the passed length parameter.
pascal (clj) Output will be: CapitalizedAndTouchingTheNext accepts strings and keywords.
phrase (clj) Output will be: Space separated with the first letter capitalized.
prune (clj) Truncates a string to a certain length and adds '...' if necessary.
quote (clj) Quotes a string.
repeat (clj) Repeats string n times.
replace (clj) Replaces all instance of match with replacement in s.
replace-first (clj) Replaces first instance of match with replacement in s.
reverse (clj) Return string reversed.
rstrip (clj)
rtrim (clj) Removes whitespace or specified characters from right side of string.
slice (clj) Extracts a section of a string and returns a new string.
slug (clj) Transform text into a URL slug.
snake (clj) Output will be: lower_cased_and_underscore_separated accepts strings and keywords.
split (clj) Splits a string on a separator a limited number of times.
starts-with? (clj) Check if the string starts with prefix.
strip (clj)
strip-newlines (clj) Takes a string and replaces newlines with a space.
strip-prefix (clj) Strip prefix in more efficient way.
strip-suffix (clj) Strip suffix in more efficient way.
strip-tags (clj) Remove html tags from string.
stylize (clj)
substr-between (clj) Find string that is nested in between two strings.
surround (clj) Surround a string with another string or character.
title (clj) Output will be: Each Word Capitalized And Separated With Spaces accepts strings and keywords.
to-bool (clj) Returns true for 1/on/true/yes string values (case-insensitive), false otherwise.
trim (clj) Removes whitespace or specified characters from both ends of string.
unescape-html (clj) Converts entity characters to HTML equivalents.
unindent (clj) Unindent multiline text.
unlines (clj) Returns a new string joining a list of strings with a newline char (\n).
unquote (clj) Unquote a string.
unsafe-concat (clj) Unsafe variant of `concat`.
unsafe-ends-with? (clj) UNSAFE version of ends-with? predicate.
unsafe-starts-with? (clj) UNSAFE version of starts-with? predicate.
unsurround (clj) Unsurround a string surrounded by another string or character.
upper (clj) Converts string to all upper-case.
uslug (clj) Unicode friendly version of `slug` function.
word? (clj) Checks if a string contains only the word characters.
words (clj) Returns a vector of the words in the string.