Skip to content
New issue

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

feat: added support for type negation with z.not() and .not() method … #3709

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Kumar06Lav
Copy link

Added support for type negation using z.not() and the .not() method in schema validation. This enhancement allows schemas to explicitly reject specific types, offering greater flexibility in data validation.

This implementation was done for ticket #2862

Changes:

Introduced the z.not() method to create schemas that reject a specified type.
Enabled the .not() method to be used directly on existing schemas for easier exclusion of types.
Added comprehensive test cases to validate the new z.not() functionality.
Updated the documentation to include examples and usage guidelines for z.not().

Copy link

netlify bot commented Aug 14, 2024

Deploy Preview for guileless-rolypoly-866f8a ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 61dc91e
🔍 Latest deploy log https://app.netlify.com/sites/guileless-rolypoly-866f8a/deploys/66bc613c4b54c60008132450
😎 Deploy Preview https://deploy-preview-3709--guileless-rolypoly-866f8a.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@Kumar06Lav
Copy link
Author

@colinhacks Could you please help me with review of my PR and merging it(if everything is fine)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant