We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi guys, I love your project but I miss a simple predicate function. For example something like this:
export const isValid = (result: Validity): boolean => { return result === undefined || (result as OptionalValidity).noContext };
I am not sure what (result as OptionalValidity).noContext does but I adapted it from assertValid.
(result as OptionalValidity).noContext
assertValid
It would make it easier to validate values, e.g.:
if (isValid(isEmail("[email protected]"))) { ... }
Would you mind adding something like this?
Thank you and Happy New Year!
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi guys, I love your project but I miss a simple predicate function. For example something like this:
I am not sure what
(result as OptionalValidity).noContext
does but I adapted it fromassertValid
.It would make it easier to validate values, e.g.:
Would you mind adding something like this?
Thank you and Happy New Year!
The text was updated successfully, but these errors were encountered: