Summary
Out of the box, VSCode will validate against whatever schema is referenced in a JSON document's $schema property; whether that is from a remote URL or a path relative to the JSON file.
Is there anything in the roadmap to feature the same in vscode-yaml?
Relevant information
Here's an example of VSCode using a relative schema (with the
$schema prop)

I found the option to reference the schema from a comment at the top of a YAML file, but I can't seem to get that to work very nicely with local schemas.
... I've tried using a path relative to the root:

... and I've tried relative to the file:


Even if I got one of the above options to work, the comment would be stripped out if I were to convert the YAML file to JSON, so doesn't quite suite my needs anyway 😞 .
Summary
Out of the box, VSCode will validate against whatever schema is referenced in a JSON document's
$schemaproperty; whether that is from a remote URL or a path relative to the JSON file.Is there anything in the roadmap to feature the same in
vscode-yaml?Relevant information
Here's an example of VSCode using a relative schema (with the$schemaprop)I found the option to reference the schema from a comment at the top of a YAML file, but I can't seem to get that to work very nicely with local schemas.
... I've tried using a path relative to the root:
... and I've tried relative to the file:Even if I got one of the above options to work, the comment would be stripped out if I were to convert the YAML file to JSON, so doesn't quite suite my needs anyway 😞 .