Skip to content

Protect against empty strings with non null string types #12

Closed
@armincerf

Description

@armincerf

I'm somewhat new to yup so maybe I'm missing something here, but what is the reason behind generating defined() for non null types rather than required()?

I only ask because required() will prevent empty strings (which is what I want for all non null string types)

Or if that's not a good reason to change it, is there any way of telling the generator I want required() for all non null strings so I don't get empty strings slipping through?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions