Skip to content

Validate list of emails #564

@Gregoirevda

Description

@Gregoirevda

How to validate a list of emails like a@a.com;b@b.com

I tried to convert the string to an array and validate each email like this, but it's difficult to mix strings and arrays:
yup.array().transform((str) => str.split(';')).of(yup.string().email()).required()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions