Skip to content

Add ascii_only option to StringConstraints #12300

@davidhewitt

Description

@davidhewitt

Initial Checks

  • I have searched Google & GitHub for similar requests and couldn't find anything
  • I have read and followed the docs and still think this feature is missing

Description

I was recently asked for a way to require ascii-only text, and couldn't see anything better than requiring a regex accepting the ascii charset range in StringConstraints.

I would think that an ascii_only option (name to be bikeshed) would be more user-friendly. It's potentially also possible to check for ascii-only characters a lot cheaper without using a regex.

Affected Components

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions