-
Notifications
You must be signed in to change notification settings - Fork 27.8k
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
Support for $ref tags/JSON schema in extension's package.json #95270
Comments
Well the issue is probably due to the |
$ref can not be used in such schema fragment as the path is resolved against the composed schema that users don't know how it looks like and should not know. |
Not a bug but a feature request. |
It sounds like there is a restriction to not have |
@weinand This needs to be documented with the |
From the site: https://code.visualstudio.com/api/references/contribution-points#Configuration-property-schema
Without ref I cannot define a recursive schema. Do I miss something?😏 |
You can only use other properties that define a constraint. I made this more explicit: microsoft/vscode-docs@7108f81 |
The Docker extension has a substantial amount of repetition in its package.json; this would be a very nice feature to have. |
Update since some folks might be interested. I found a rather hacky way to accomplish this--I tried it for settings but it may also work for tasks/launch configs as well. Please note, it only helps with the settings JSON editor, not in the settings UI (which will simply send you to the JSON). You can use Basically what I did is:
If there is already some built-in |
I work on a VS Code Extension, and I'm following up on #95033 . It looks like this issue was caused by the fact that we were using a
$ref
field within the package.json manifest. This appears to be an invalid use of package.json, given the unusual behavior shown in #95033. Could you please explain whether or not this is valid in package.json?To offer some insight, we have embedded a JSON Schema into the
debugger
contribution point. The motivation was to use a code generator against the JSON schema to ensure the extension code remains in sync with the structure defined in the manifest. If this scenario is not valid, we'd be interested in hearing a recommended way to keep the manifest and code structures in sync.Thanks in advance!
The text was updated successfully, but these errors were encountered: