-
Notifications
You must be signed in to change notification settings - Fork 37.9k
Description
(great, clicked a github popup and lost everything i've wrote, here we go again)
- VSCode Version: master branch
- OS Version: Windows 10
Steps to Reproduce:
Its quite complicated
Does this issue occur when all extensions are disabled?:
Yes, but the issue is with an extension im building.
Currently the typescript language feature extension uses the LanguageProvider to register capabilities for a ts-based language from a tsserver plugin. The thing is, when creating the descriptor for the languageProvider, the TypeScriptServiceClientHost hardcodes the "typescript-plugins" id to the descriptor, later, when the language provider gets registered, there are some language capabilities, like completions, formatting, implementationsCodeLens, jsDocCompletions, referencesCodeLens, dependentRegistration and tagClosing, that use the ConfigurationDependentRegistration, which as the name says, it registers the capability only if a certain config value is set to truthy. That config is based on the descriptors id, which is used as a main section to search the config file, it ends up doing
vscode.workspace.getConfiguration(descriptor.id, null).get('suggest.enabled')
where descriptor.id is "typescript-plugins".
Im currently working around it, and configured my contributions as follows
{
"configuration": {
"title": "Vue-lang",
"properties": {
"typescript-plugins.suggest.enabled": {
"type": "boolean",
"default": true,
"description": "Enable the usage of intellisense."
},
"typescript-plugins.format.enable": {
"type": "boolean",
"default": true,
"description": "Enable/disable the vue document formatter."
},
"typescript-plugins.implementationsCodeLens.enabled": {
"type": "boolean",
"default": true,
"description": "Enable/disable the vue document implementations CodeLens helper"
},
"typescript-plugins.suggest.completeJSDocs": {
"type": "boolean",
"default": true,
"description": "Enable/disable the vue document suggestions for jsDocs."
},
"typescript-plugins.referencesCodeLens.enabled": {
"type": "boolean",
"default": true,
"description": "Enable/disable the vue document references CodeLens helper."
},
"typescript-plugins.autoClosingTags": {
"type": "boolean",
"default": true,
"description": "Enable/disable the vue document auto closing tags."
}
}
}
}
notice my config section, has to be typescript-plugins.
Perhaps that value could be included in the contributes.typescriptServerPlugins
contributes.typescriptServerPlugins.configNamespace: "string"
// or
contributes.typescriptServerPlugins.capabilities: ["arrayOfString"]
kinda offtopic:
are there any other language provided feature that are enabled like those listed in my issue? might just ask since i have you guys here