Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
dry-validations
Search
Krzysztof Wawer
September 23, 2016
Programming
0
150
dry-validations
Krzysztof Wawer
September 23, 2016
Tweet
Share
More Decks by Krzysztof Wawer
See All by Krzysztof Wawer
The Good Architecture
wafcio
0
570
GIT - Good Practices
wafcio
0
54
Slim Ruby on Rails: Controllers & Middlewares
wafcio
1
140
Dry System
wafcio
0
89
Validations in Ruby
wafcio
0
160
Generating a CSV file with ROM
wafcio
0
270
Trailblazer bez trailblazera
wafcio
0
190
ActiveRecord, DataMapper czy Agregacja encji
wafcio
0
140
Jak (nie) używać Service Object
wafcio
0
170
Other Decks in Programming
See All in Programming
Rubyで始める関数型ドメインモデリング
shogo_tksk
0
130
PRレビューのお供にDanger
stoticdev
1
220
未経験でSRE、はじめました! 組織を支える役割と軌跡
curekoshimizu
1
120
CSS Linter による Baseline サポートの仕組み
ryo_manba
1
140
color-scheme: light dark; を完全に理解する
uhyo
7
480
15分で学ぶDuckDBの可愛い使い方 DuckDBの最近の更新
notrogue
1
370
Amazon Q Developer Proで効率化するAPI開発入門
seike460
PRO
0
120
ソフトウェアエンジニアの成長
masuda220
PRO
12
2.1k
Multi Step Form, Decentralized Autonomous Organization
pumpkiinbell
1
830
From the Wild into the Clouds - Laravel Meetup Talk
neverything
0
100
Better Code Design in PHP
afilina
0
160
コードを読んで理解するko build
bells17
1
100
Featured
See All Featured
The Illustrated Children's Guide to Kubernetes
chrisshort
48
49k
Code Reviewing Like a Champion
maltzj
521
39k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
45
9.4k
Building a Scalable Design System with Sketch
lauravandoore
461
33k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
The Cult of Friendly URLs
andyhume
78
6.2k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.7k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
4
430
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
175
52k
Adopting Sorbet at Scale
ufuk
74
9.2k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
10
1.3k
Fireside Chat
paigeccino
34
3.2k
Transcript
Krzysztof (Christopher) Wawer @wafcio about.me/kwawer
Our API • Roda • ROM (Ruby Object Mapper) •
JSON API standard (http://jsonapi.org)
{ price: 1000 } => { price: '1000' } /\d+/
dry-validation Piotr Solnica Andy Holland http://dry-rb.org/gems/dry-validation/
Community • 17 contributors • very active Gitter channel https://gitter.im/dry-rb/chat
• v0.10.1 • used in hanami-validations, reform
Strange and awesome things
Predicate Logic • and ( & ) • or (
| ) Dry::Validation.Schema do required(:age) { int? & gt?(18) } end
Optional Keys and Values { age: 30 } { name:
nil, age: 30 }
Nested data { name: "John", address: { street: "Main Street"
}, emails: ["
[email protected]
"] }
Shared schema Dry::Validation.Schema do required(:name).filled required(:address).schema(AddressSchema) end
dry-validation http://dry-rb.org/gems/dry-validation/
Thanks @wafcio about.me/kwawer