When using nested patternProperties regex not works #626
Replies: 2 comments 2 replies
-
JSON Schema, per the specification, will just ignore that property. |
Beta Was this translation helpful? Give feedback.
-
I can't speak for proprietary VSCode functionality, but I did notice a bug in your schema that could be the cause of the problem "oneOf": [
{
"$ref": "#/definitions/kebabCase"
},
{
"type": "object",
"patternProperties": {
"^[a-z0-9_]+$": {
"$ref": "#/definitions/kebabCase",
"errorMessage": "Invalid property name. Use snake_case."
}
}
}
],
"additionalProperties": false The scope of There's a keyword called |
Beta Was this translation helpful? Give feedback.
-
When I use nested patternProperties, in the key the regex works but the error message is the default one and not the one I defined in the scheme and in the subkey the error follows what is defined but the regex does not work, it reports an error even though it is correct.
I'm using VSCode.
//color-semantic.schema.json
//color-semantic.tokens.json
Beta Was this translation helpful? Give feedback.
All reactions