These are chat archives for dry-rb/chat
Next-gen ruby libs! » github.com/dry-rb » website: https://dry-rb.org » forum: https://discourse.dry-rb.org
dry-validationoverlap with reform on what they can do.
#attrpredicate which is synonymous to
#keybut used for method access rather than
#access, if that's what you meant in the issue above?
#for property access
attr. What sentence do you mean ? :-)
attris probably better, but I wouldn’t like it
I believe the way
dry-v should be used is shown best in formalist, where data validation appears first and then, upon the result and form "schema", the AST is being built. The same I think about Reform. However, Reform is built with a concept of twins, where each twin object is just a twin of the real model in AR and essentially, any thing you may want to perform before persistence state, is going to be performed on twin, not the real model. Validation process is also fired against twins
I asked about validating objects and what @AMHOL tried to clarify to me, because Reform validates objects. However it's possible to serialize it to hash with primitives, I feel this is not right since there're already built object graph (twins)