Sha256: 70a37fb568acbf1380b74921f8379b9be83ee6a7851b1593ea2647647b2f21db
Contents?: true
Size: 289 Bytes
Versions: 26
Compression:
Stored size: 289 Bytes
Contents
require 'dry-validation' schema = Dry::Validation.Schema do required(:email).filled required(:age).filled(:int?, gt?: 18) end errors = schema.call(email: 'jane@doe.org', age: 19).messages puts errors.inspect errors = schema.call(email: nil, age: 19).messages puts errors.inspect
Version data entries
26 entries across 26 versions & 1 rubygems