Accord is an interesting lib for validations. Accord is composable, simple, self-contained, and integrated with ScalaSpecs for instance. In Java, validations are often done via annotations. In general, there is an abuse of annotations in Java mostly because there is a lack of Macros which we have in Scala and Rust for instance. I really like the Accord approach to validations where we dont throw Exceptions and we can extend and re-use validations across the type system. So today I made a simple code with Scala and Accord using SBT as-built system and a video to explain in more detail. So let’s get started.
Scala Code using scala libraries and frameworks, it`s a playground for fun with Scala. - diegopacheco/scala-playground
Originally published at http://diego-pacheco.blogspot.com on January 10, 2021.