Hi Mike! You might talk to Zack at CapClug. The session before the one you
attended he walked through two small Clojure projects, with and without
Prismatic schema.
On Saturday, May 17, 2014 2:22:51 PM UTC, Mike Fikes wrote:
I've never used a dynamically-typed language and an issue I've
I've never used a dynamically-typed language and an issue I've encountered
with Clojure is a difficulty with readily seeing the data structures
being consumed or returned by functions I'm writing, especially when I come
back to them several days later and if those structures get to be somewhat
There were a number of talks at the Conj that spoke directly to this
challenge. One of the approaches I liked was Prismatic's schema.
https://github.com/Prismatic/schema
And here's Aria's talk on it, since he can explain it better than I.
https://www.youtube.com/watch?v=o_jtwIs2Ot8
On Sat,
I've been toying around with the idea of type signatures that exist
specifically for documentation purposes, loosely inspired by the stack
effect declarations in Factor.
For example, in your case we might start with something like:
(defn count-items
{:doc/type '([{Keyword String} - Integer])}
Check out Prismatic's schema:
https://github.com/Prismatic/schema
With validation turned off that's exactly what the library provides.
James Reeves mailto:ja...@booleanknot.com
May 17, 2014 11:42 AM
I've been toying around with the idea of type signatures that exist
specifically for
Ah, sorry, didn't see your reference at the bottom :)
Schema does augment the docs to some degree:
paddleguru.models.transfer/payout!
([regatta balance our-fee their-fee])
Inputs: [regatta :- regatta/Regatta balance :- graph/Balance our-fee
:- s/Num their-fee :- s/Num]
Returns: {:success