-
Notifications
You must be signed in to change notification settings - Fork 46
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
"additionalProperties" behavior like JSON Schema #18
Comments
Hi, I don't think this exists, I don't recall implementing it, but believe I considered it. I imagine it would be fairly trivial to implement, looking at the code again, we could possibly add a Is this something that is important to you? Can you describe a use-case please? |
@freeformsystems thank you for your reply! Our use-case was related to security and due to the emergency of the situation, we had to make a workaround :) Basically, if you don't strict to the schema, you can inject any other key to your object model and bypass the validation of that key. Best regards, |
Draft implementation for nested objects in 17e2e79. Needs work to operate at the root source object level as well. Set https://github.com/freeformsystems/async-validate/blob/master/test/spec/object-additional.js |
I need to test this a little more but I think it should be working with the addition of the ability to apply validation rules to the root Relevant test spec is: https://github.com/freeformsystems/async-validate/blob/master/test/spec/source-additional.js |
Closing as implemented, this is available in https://github.com/freeformsystems/async-validate/blob/master/test/spec/additional.js Re-open if you find an issue with this functionality. |
Hi guys!
Do you know if there's anything like JSON schema "additionalProperties" in async validate do refuse validation if there's any additional properties been sent?
Best regards!
cc @MarcosRava
The text was updated successfully, but these errors were encountered: