These are chat archives for dry-rb/chat

6th
Aug 2016
Sergey Kukunin
@Kukunin
Aug 06 2016 00:30
Can I define custom coercing for the dry-types?
For example, I want to have Phone type, which validates and normalizes input phone?
Sergey Kukunin
@Kukunin
Aug 06 2016 00:38
found from https://github.com/dry-rb/dry-types/blob/master/lib/dry/types/core.rb: I can use .constructor()
Tim Riley
@timriley
Aug 06 2016 01:47
Yep, that's what you want.
Sergey Kukunin
@Kukunin
Aug 06 2016 01:58
thanks guys