4 ms·
>An e-mail address could be passed into a function that requires a non-empty string as input. When the type-system knows that an e-mail string is a subclass of
by croes 3y ago
>An e-mail address could be passed into a function that requires a non-empty string as input. When the type-system knows that an e-mail string is a subclass of non-empty string, it knows that an email address is valid.
Don't use regex for email address validation
https://news.ycombinator.com/item?id=31092912 https://news.ycombinator.com/item?id=31092912