4 ms·
What timing! I have been making this exact thing myself. Would you be interested in pull requests making your api simpler? Maybe allow parameters to not have t
by JackMorgan 13y ago
What timing! I have been making this exact thing myself.
Would you be interested in pull requests making your api simpler? Maybe allow parameters to not have to have shapes? Perhaps allowing a syntax that allows a simple way to shapes in the meta alongside the ability to change the signature for people who don't want to couple too tightly to the library? When I showed mine to my local user group last month, that was one of their biggest requests (that I was in the middle of on mine but would be happy to attempt in yours).
Check my (simpler and more immature) library here
https://github.com/steveshogren/deft https://github.com/steveshogren/deft
- JackMorgan 13y agoAlso, what about having your defn macro generate a second function like foo-t that just calls with-fn-validation on foo, to clean up that extra call? Would you be interested in such a pull request?
- w01fe 13y agoI'd have to think about that a bit -- I'm hesitant to create names not provided by the user, but maybe there is another way. Quite honestly that part of things (turning validation on and off, etc) isn't really done yet -- we have plans to make it much more flexible and powerful, but haven't got there yet.
- JackMorgan 13y agoI really like that your defn macro generates a real function, good call on that!
- w01fe 13y agoSure, we're happy to consider pull requests. Schemas are already optional -- you can have a s/defn with no, some, or full schematization. You can also put the schemas in the meta if you don't like the :- syntax. I'm not quite sure what you mean by the other point though. My email is in my profile, let's talk :)