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

configurePlugins command for tsserver #28106

Merged
merged 3 commits into from
Oct 29, 2018

Conversation

minestarks
Copy link
Member

Implements #18604

  • Add a new tsserver command, configurePlugins.
  • Add a new optional method to PluginModule, onConfigurationChanged. Plugin authors can implement this.
  • When configurePlugins is invoked, it will pass on the configuration object to any loaded plugin instances with a matching name.
  • This configuration is meant to override the initial configuration passed in in create/PluginCreateInfo as well as any previous configurations passed in in configurePlugins.
  • The updated configuration will also be remembered by tsserver so that it can be passed in, in the create call, to any projects loaded in the future with the matching plugin. This is needed for consistency -- the caller of configurePlugins would have no way of knowing whether the plugin/project of interest has yet been loaded.

cc @mjbvz

@minestarks minestarks changed the title Configure plugins configurePlugins command for tsserver Oct 24, 2018
Copy link
Contributor

@mjbvz mjbvz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API changes for server and plugins look good! Just let me know how you want us to expose this on the VS Code side

@minestarks
Copy link
Member Author

@mjbvz Thanks! Just opened corresponding PR microsoft/vscode#61756 , let me know if that works.

@sheetalkamat
Copy link
Member

Changes look good but we need test.

@zafarmandor786
Copy link

Thanks

@minestarks
Copy link
Member Author

@sheetalkamat test added!

@sheetalkamat
Copy link
Member

Build failed with api

@minestarks minestarks merged commit 83c38f3 into microsoft:release-3.1 Oct 29, 2018
minestarks added a commit to minestarks/TypeScript that referenced this pull request Oct 29, 2018
minestarks added a commit that referenced this pull request Oct 29, 2018
Merge pull request #28106 from minestarks/configure-plugins
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants