Skip to content

Ability to validate strings as numbers #62

Description

@davidmoshal

Is your feature request related to a problem? Please describe.

Ability to validate if a string is a number.
Additionally, if it is a number, ability to validate as a number.
eg: if it's positive, is less than or greater than x, etc.

Describe the solution you'd like

Assuming a system which receives parameters as strings via REST.
(which is actually all http requests, as string, and string arrays, are the only parameter type).

I'd like to be able to validate as follows:

validate(Employee::age).isNumber().isPositive()

Additional context

Add any other context or screenshots about the feature request here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions