Pregunta de entrevista de Johnson & Johnson

How do you validate emails in front-end development?