Tags
Here's my thought on ๐ญ Network Types - Pydantic
pydantic has a nice built in email validator EmailStr
It requires an optional pydantic dependency
pip install email-validator
Then you can validate email addresses.
from pydantic import BaseModel, EmailStr class Model(BaseModel): email: EmailStr print(Model(email='contact@mail.com')) #> email='contact@mail.com'
Note
This post is a thought. It's a short note that I make about someone else's
content online. Learn more about the process
thoughts
This post was a thought by Waylon Walker see all my thoughts at https://waylonwalker.com/thoughts