Skip to content
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

VS Code Extension Config API #18476

Open
alexander-heimbuch opened this issue Nov 4, 2024 · 0 comments
Open

VS Code Extension Config API #18476

alexander-heimbuch opened this issue Nov 4, 2024 · 0 comments
Labels
C-feature Category: feature request

Comments

@alexander-heimbuch
Copy link

Our VS Code extension integrates with the Rust Analyzer extension. In order for Rust Analyzer to work in our environment, it needs dynamic values in the configuration. So far we update the settings.json according to the dynamic values, but this leads to overwriting any configurations of the user and leaving the workspace in a potential dirty state. Accordingly, a different configuration interface would be desirable.

VS Code Extensions offer the possibility to expose an API via the activate hook, here a config function could be added, which enables a configuration in an extension to extension communication:

const rustAnalyzer = vscode.extensions.getExtension("rust-lang.rust-analyzer")?.exports;

await rustAnalyzer.config({ ... });

This function should respect the existing configuration (user configurations have precedence).

@alexander-heimbuch alexander-heimbuch added the C-feature Category: feature request label Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature Category: feature request
Projects
None yet
Development

No branches or pull requests

1 participant