cljs.spec.alpha/spec

macropreviously cljs.spec/spec clojure.spec.alpha/specEdit
(spec form & {:keys [gen]})

Source docstring:
Takes a single predicate form, e.g. can be the name of a predicate,
like even?, or a fn literal like #(< % 42). Note that it is not
generally necessary to wrap predicates in spec when using the rest
of the spec macros, only to attach a unique generator

Can also be passed the result of one of the regex ops -
cat, alt, *, +, ?, in which case it will return a regex-conforming
spec, useful when nesting an independent regex.
---

Optionally takes :gen generator-fn, which must be a fn of no args that
returns a test.check generator.

Returns a spec.
Source code @ clojurescript:src/main/cljs/cljs/spec/alpha.cljc
(defmacro spec
  [form & {:keys [gen]}]
  (when form
    `(spec-impl '~(res &env form) ~form ~gen nil)))