malli

https://github.com/metosin/malli :malli:
ikitommi 2020-04-30T08:36:04.431500Z

@teodorlu Agree, would be useful. I think someone could make a thesis (and read other people theses ;)) out of the providers. The current impl is really naive (69 loc), help most welcome. Ambrose might have some math for this already on typed clojure

👍 1
ikitommi 2020-04-30T08:36:31.431600Z

ikitommi 2020-04-30T08:36:58.431900Z

teodorlu 2020-04-30T08:38:14.432700Z

I'll have a look at the provider source 🙂

daveliepmann 2020-04-30T14:39:52.435Z

@teodorlu I had a similar thought under which your hypothetical looked like [:map [:strength int?] #{"mage" "paladin" "ranger"}] in my head 🙂

😄 1
daveliepmann 2020-04-30T14:46:21.439500Z

The shortest real example I have is [:map-of #{<domain-specific items>} [:map-of #{<more domain-specific items>} boolean?]] . (The first set of domain items is limited but long enough to make me not want to enumerate each key to the same spec of values; the second set of domain items is IDs from another system that can't be enumerated in a spec but that I might want to check the existence of.) On some of the larger schemas I can see some difficulty getting the API for mp/provide to play nicely with a skeleton schema, because of how nested it would have to be.