ingesol 2021-07-05T08:15:34.274400Z

@olivergeorge I have found to be a great match for that. You can spec as much or as little as you want, with pretty minimal boilerplate. Would love malli support, but this works great.

(d/fn [{:keys [^::db-that-contains-form db]} [_ & ^::my-coll-spec args]]
    {:db (assoc db :something args)})

ingesol 2021-07-05T08:38:13.274600Z

Ah, @vemv, didn’t notice you already answered this. I’m using speced.def, find it to be a great fit for re-frame events and subs

ingesol 2021-07-05T08:39:25.274800Z

primarily because of verbosity. There are many great libraries for specing functions, but I didn’t find any other that allows you to do something like this

(d/fn [{:keys [^::db-that-contains-form db]} [_ & ^::my-coll-spec args]]
    {:db (assoc db :something args)})

vemv 2021-07-05T11:06:05.275Z

Yes speced.def remains unique in destructuring support, and specing beyond defn (defprotocol, fn, let, etc) One thing that probably would be handy for cljs usage is failing asynchronously or in a custom manner so that the SPA won't fail irreversibly (as it can happen with :pre). I have related work in a branch, I simply haven't proceeded b/c I don't know much about who's using speced.def or their needs (and have my OSS plate quite full)

vemv 2021-07-05T11:11:58.275200Z

😊 The 'core' of this library is completely decoupled from spec. Last winter I made it work with with Plumatic Schema with very little code. I could do the same for Malli, it's basically a matter of "who's gonna use this" I did propose it in Malli and perceived little interest

ingesol 2021-07-05T13:10:16.275400Z

Yes, I noticed. And interest seems pretty slim in general. I do think though that interest could pick up by highlighting the strengths that makes this one stand out from the others.

vemv 2021-07-05T13:13:38.275600Z

I think it was bad timing most of all... it was released after some other libs, and also while we spec users live in some sort of limbo between spec1 and spec2... with interesting alts like Malli popping up in general I've abstained from promoting much the lib. I want to see where spec2 goes and likewise if clojure.core will integrate it

ingesol 2021-07-05T13:25:23.275800Z

I can only speak for myself, but so far there hasn’t been a need for CLJS specific handling. The type errors I want to catch don’t happen much in the wild

ingesol 2021-07-05T13:25:40.276Z

so mostly a dev tool for us, at least so far

ingesol 2021-07-05T20:42:23.276400Z

I wrote about our use of spec validation for re-frame events and subs

ingesol 2021-07-05T20:47:50.276500Z

Well, all PR is good PR…

Oliver George 2021-07-05T21:19:19.277100Z

Nice! Thanks everyone.