(deep-merge & maps)
Like merge, but merges maps recursively. See: https://dev.clojure.org/jira/browse/CLJ-1468
Like merge, but merges maps recursively. See: https://dev.clojure.org/jira/browse/CLJ-1468
(find-first pred coll)
Finds the first value from coll that satisfies pred. Returns nil if it doesn't find such a value.
Finds the first value from coll that satisfies pred. Returns nil if it doesn't find such a value.
(find-index pred coll)
Returns the index of the first value in coll
that satisfies pred
Returns the index of the first value in `coll` that satisfies `pred`
(group-by-keyword kw coll)
Same as group-by but dissocs the keyword used for grouping the items
Same as group-by but dissocs the keyword used for grouping the items
(index-by keyword coll)
Indexes a collection using the given keyword as key
Indexes a collection using the given keyword as key
(map-kv f m)
Syntax sugar for map->map transformations
Syntax sugar for map->map transformations
(map-leaves f v)
Applies f to all 'leaves' (anything that is not sequential or a map)
Applies f to all 'leaves' (anything that is not sequential or a map)
(mapm f coll)
(mapm f c1 c2)
(mapm f c1 c2 c3)
(mapm f c1 c2 c3 & colls)
Like clojure.core/mapv, but creates a map
Like clojure.core/mapv, but creates a map
(remove-nil-vals m)
Removes nil values from a map
Removes nil values from a map
(tree-by id-key parent-key coll & [parent])
Creates a recursive structure from a flat structure
Creates a recursive structure from a flat structure
(update-when-some m k f)
Like update
but does not do anything if the value does not exist or is nil
Like `update` but does not do anything if the value does not exist or is nil
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close