malli 2026-11-06

is it possible to pretty print a schema? clojure.pprint/pprint didn’t do what i was hoping

✅ 1

Have you tried m/explain ? Is it near what you are looking for or is it too verbose?

i don’t want to print a value, i want to take a [:merge [:map …] [:map …]] schema and then pretty print it

(clojure.pprint/pprint
  (m/schema [:merge
             [:map [:a :int] [:b :int] [:c :int][:d :int][:e :int][:f :int][:g :int]]
             [:map [:b :string] [:c :string]]]))
; [:merge [:map [:a :int] [:b :int] [:c :int] [:d :int] [:e :int] [:f :int] [:g :int]] [:map [:b :string] [:c :string]]]
when what i’d like is
(clojure.pprint/pprint
  (m/schema [:merge
             [:map [:a :int] [:b :int] [:c :int][:d :int][:e :int][:f :int][:g :int]]
             [:map [:b :string] [:c :string]]]))

; [:map
;  [:a :int]
;  [:b :string]
;  [:c :string]
;  [:d :int]
;  [:e :int]
;  [:f :int]
;  [:g :int]]

soemthing that builds and derefs the schema (to perform merges, insert registry entries, etc), and then pretty-prints it, or at least returns the schema as data so i can pretty-print it myself

form?

➕ 1

ah yes, that’s it. thank you

🫡 1