(def kw-spec|sym-pred fn|message)
Define a message for a given spec or a predicate. Arguments:
Define a message for a given spec or a predicate. Arguments: - either a keyword (spec) or a qualified symbol (for a predicate); - either a string or 1-arg function that takes a problem map and returns a message.
(def-many key->messages)
Define multiple messages at once. Takes a map of sym/keyword => message/function values.
Define multiple messages at once. Takes a map of sym/keyword => message/function values.
(explain spec value)
Prints the formatted output of explain-data.
Prints the formatted output of explain-data.
(explain-data spec value)
Like s/explain-data: takes a spec and a value and returns a map with the problem list. Each problem has clear message found by either a predicate or a spec.
Like s/explain-data: takes a spec and a value and returns a map with the problem list. Each problem has clear message found by either a predicate or a spec.
(explain-str spec value)
Like explain, but returns the captured output as a string.
Like explain, but returns the captured output as a string.
(undef kw-spec|sym-pred)
Undefine a message for the given sym/kw.
Undefine a message for the given sym/kw.
(undef-all)
Undefine all the known messages.
Undefine all the known messages.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close