Liking cljdoc? Tell your friends :D

baredom.utils.model


non-empty-string?cljs

(non-empty-string? value)

True when value is a string with at least one character.

True when value is a string with at least one character.
sourceraw docstring

parse-bool-attrcljs

(parse-bool-attr s)

HTML boolean-attribute semantics: an attribute is true when it is present with any value other than the literal string "false". The empty string and "0" both count as true. Pass the value of getAttribute (a string or nil); never the result of hasAttribute. For strict presence semantics use parse-bool-present.

HTML boolean-attribute semantics: an attribute is true when it is
present with any value other than the literal string `"false"`.
The empty string and `"0"` both count as true. Pass the value of
`getAttribute` (a string or `nil`); never the result of
`hasAttribute`. For strict presence semantics use `parse-bool-present`.
sourceraw docstring

parse-bool-presentcljs

(parse-bool-present s)

Strict-presence variant of parse-bool-attr: true when the attribute exists at all, regardless of value. Pass the value of getAttribute (a string or nil).

Strict-presence variant of `parse-bool-attr`: true when the attribute
exists at all, regardless of value. Pass the value of `getAttribute`
(a string or `nil`).
sourceraw docstring

safe-url?cljs

(safe-url? url)

Returns true when url uses an allowed protocol or is a relative URL.

Returns true when url uses an allowed protocol or is a relative URL.
sourceraw docstring

sanitize-svg-path-dcljs

(sanitize-svg-path-d s)

Strips characters that are not valid in an SVG path d-attribute. Returns nil if the result is blank.

Strips characters that are not valid in an SVG path d-attribute.
Returns nil if the result is blank.
sourceraw docstring

sanitize-urlcljs

(sanitize-url url)

Returns the url unchanged when safe-url? accepts it; otherwise the empty string. Note: nil and the empty string both round-trip to "", so callers cannot use the return value to distinguish "missing url" from "unsafe url" — guard with safe-url? directly when that distinction matters.

Returns the url unchanged when `safe-url?` accepts it; otherwise the
empty string. Note: nil and the empty string both round-trip to `""`,
so callers cannot use the return value to distinguish "missing url"
from "unsafe url" — guard with `safe-url?` directly when that
distinction matters.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close