map->Record
constructors being redefined.s/defn
or s/defrecord
.deftype
).^{:schema ..}
style annotations. :- schema
is the preferred way, but metadata-style schemas are still allowed for valid Clojure typehints.:- Protocol
annotations (use :- (s/protocol Protocol)
instead).defn
, defrecord
, etc) from schema.macros. The identical versions in schema.core remain.*use-potemkin*
flag. To get the old behavior of potemkin defrecords, you can still bring your own potemkin and use schema.core/defrecord+
in place of schema.core/defrecord
.defschema
which clobbered metadata, breaking s/protocol
in Clojure in 0.3.2.s/protocol
in Clojure (didn't work properly with extends created later)set-compile-fn-validation!
function to turn off emission of validation globally, and turn off emission of validation code for non- ^:always-validate functions when assert is false.clojure.data/diff
and class
inside error messages.schema.macros
in client code -- prefer canonical versions in schema.core
in both Clojure and ClojureScript, using :include-macros true
in cljs.^{:s schema}
syntax for providing schemas.*use-potemkin*
flag and behavior to default to potemkin s/defrecords in Clojure;
in future releases, you will have to provide your own potemkin and explicitly opt-in to this behavior.isa
schema for Clojure hierarchies.normalized-defn-args
helper fn for defining s/defn
-like macros.s/recursive
to work on artibrary refss/Symbol
as a cross-platfor primitives/def
.s/defmethod
.Bool
coercions.Bool
to cross-platform primitivescheck
with walker
, for increased speed and versatilitylongs
, etc)letfn
s/defn
:never-validate
meta options/defn
(thanks danielneal)set-fn-validation!
to schema.core, to globally turn validation on or off.:always-validate
metadata on fn/defn name to unconditionally use validation.defschema
puts name in metadata, rather than generating named schemas/defn
Can you improve this documentation? These fine people already did:
Jason Wolfe, loganlinn, Daniel Neal, Jason Whitlark & Kimmo KoskinenEdit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close