microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.9k stars 29.52k forks source link

Add an `onExtensionActivated` activation event #146547

Open isc-bsaviano opened 2 years ago

isc-bsaviano commented 2 years ago

I have an extension (https://github.com/intersystems/language-server) that depends on another one (https://github.com/intersystems-community/vscode-objectscript). Instead of having to duplicate activation events between them to ensure that the dependent extension always activates when the main extension does, it would be nice to have a single activation event onExtensionActivated:intersystems-community.vscode-objectscript.

joyceerhl commented 1 year ago

Is this use case addressed by declaring intersystems-community.vscode-objectscript in the extensionDependencies of the language server extension to ensure the dependencies are activated first?

isc-bsaviano commented 1 year ago

@joyceerhl Child extension intersystems.language-server has parent extension intersystems-community.vscode-objectscript as an extension dependency, which ensures that the parent is always active before the child. However, that does not guarantee that the child will get activated whenever the parent does, which is what this feature request is about.