You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The file is correctly validated, but the "age" property is not shown in the editor, and neither is it possible to add new properties (allowed by the schema). Also, if I change "age" to "25" (a string), the JSON is still validated, even if it is invalid. It even validates with additionalProperties: false...
In other words, it looks like the additionalProperties keyword is ignored in the schema.
I have also tested patternProperties and it does not work either,
I could understand if you did not want to have additional properties in the editor (since without additionalProperties: false, one can add anything anywhere), but it would be nice if the validating worked correctly and also if the already present (and valid) keys we shown in the editor...
The text was updated successfully, but these errors were encountered:
I think validation should work as expected as this is not part of VJE, but the UI does not yet support all JSON Schema features... but I accept PRs :-)
I am not sure what you mean by "should work", but the validation clearly does not work, since it validates files that break the additionalProperties or patternProperties requirements. If the validation is not part of VJE, can you file a bug upstream?
The following example (taken from https://cswr.github.io/JsonSchema/spec/objects/) does not work:
The file is correctly validated, but the "age" property is not shown in the editor, and neither is it possible to add new properties (allowed by the schema). Also, if I change "age" to "25" (a string), the JSON is still validated, even if it is invalid. It even validates with
additionalProperties: false
...In other words, it looks like the
additionalProperties
keyword is ignored in the schema.I have also tested
patternProperties
and it does not work either,I could understand if you did not want to have additional properties in the editor (since without
additionalProperties: false
, one can add anything anywhere), but it would be nice if the validating worked correctly and also if the already present (and valid) keys we shown in the editor...The text was updated successfully, but these errors were encountered: