Liking cljdoc? Tell your friends :D

uk.axvr.refrain

Collection of useful Clojure utilities.

Collection of useful Clojure utilities.
raw docstring

assoc*clj/s

(assoc* m & kvs)

Like clojure.core/assoc, but won't assoc if key or val is nil.

Like `clojure.core/assoc`, but won't assoc if key or val is nil.
sourceraw docstring

contrastclj/s

(contrast op)
(contrast op obj & objs)

Contrast multiple comparable objects with each other with op. (Wrapper around clojure.core/compare.) Example ops: < > <= >= = not=

Contrast multiple comparable objects with each other with op.  (Wrapper
around `clojure.core/compare`.)  Example ops: < > <= >= = not=
sourceraw docstring

deep-mergeclj/s

(deep-merge & colls)

Like clojure.core/merge, but recursively merges maps.

Like `clojure.core/merge`, but recursively merges maps.
sourceraw docstring

deep-merge-withclj/s

(deep-merge-with _ coll)
(deep-merge-with f c1 c2)
(deep-merge-with f c1 c2 & cs)

Like clojure.core/merge-with, but recursively merges maps.

Like `clojure.core/merge-with`, but recursively merges maps.
sourceraw docstring

derefable?clj/s

(derefable? ref)

Returns true if clojure.core/deref can be called on ref.

Returns true if `clojure.core/deref` can be called on ref.
sourceraw docstring

dissoc-inclj/s

(dissoc-in m [k & ks])

Dissociates an entry from a nested associative structure returning a new nested structure. ks is a sequence of keys. Any empty maps that result will not be present in the new structure.

Dissociates an entry from a nested associative structure returning a new
nested structure.  ks is a sequence of keys.  Any empty maps that result
will not be present in the new structure.
sourceraw docstring

in?clj/s

(in? coll elm)

Returns true if coll contains elm.

Returns true if coll contains elm.
sourceraw docstring

macro-body-optsclj/s

(macro-body-opts [opts & body :as params])

Helper for creating macros that accept an optional map of options in their body. Call this function in your macro on the rest-body param and it will return a vector containing the option map and the rest of the body.

An option map will be found if there were more than one form in the body and the first form is a map.

Helper for creating macros that accept an optional map of options in their
body.  Call this function in your macro on the rest-body param and it will
return a vector containing the option map and the rest of the body.

An option map will be found if there were more than one form in the body and
the first form is a map.
sourceraw docstring

read-edn-resourceclj

(read-edn-resource path)

Read an EDN file at path from JVM resources.

Read an EDN file at path from JVM resources.
sourceraw docstring

regexp?clj/s≠

clj
(regexp? x)

Returns true if x is a Java regular expression pattern.

Returns true if x is a Java regular expression pattern.
cljs

Alias to cljs.core/regexp?. This exists purely to make writing *.cljc files that need regexp? easier.

Alias to `cljs.core/regexp?`.  This exists purely to make writing *.cljc
files that need `regexp?` easier.
source (clj)source (cljs)raw docstring

submap?clj/s

(submap? map1 map2)

Returns true if map1 is a subset of map2.

Returns true if map1 is a subset of map2.
sourceraw docstring

trim-endclj/s

(trim-end s substr)

Trim substr from the end of s.

Trim substr from the end of s.
sourceraw docstring

trim-startclj/s

(trim-start s substr)

Trim substr from the start of s.

Trim substr from the start of s.
sourceraw docstring

when-let*clj/smacro

(when-let* bindings & body)

Short circuiting version of clojure.core/when-let on multiple binding forms.

Short circuiting version of `clojure.core/when-let` on multiple binding
forms.
sourceraw docstring

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

× close