metosin/malli

Feature: Using Java classes as schemas

Open

#1,007 创建于 2024年2月2日

在 GitHub 查看
 (5 评论) (1 反应) (0 负责人)Clojure (237 fork)batch import
enhancementhelp wanted

仓库指标

Star
 (1,724 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Occasionally, it is necessary to drop down to Java interop. When that happens, I don't want to lose the ease and simplicity of Malli's validation, and I don't want to have to write my own custom :fn schema each time merely to call (instance? SomeClass value).

It would be helpful to have support for recognizing Java classes, effectively wrapping instance? for general use. I looked at the malli.core code and I'm not entirely sure how to accomplish this or I'd offer to do it.

Thanks so much

贡献者指南