Add an option to enable/disable JSDoc autocomplete (#23704)

* Add new option to disable/enable jsdoc autocompletion

* Refactor JsDocCompletionItem

- remove internal command
- move TS service call and template generation to CompletionItem
- only call TS service if JSDoc completion is enabled in settings
- add local config and config update method to CompletionProvider

* Change how and when JsDocCompletionHelper is registered

Register JsDocCompletionHelper and update configuration in registerProviders instead of activate. Also react to configuration change.

* Rename JsDocCompletionHelper to JsDocCompletionProvider

* Add missing newline at the eof

* Restore completion prompt for JSDoc autocomplete

Restores internal command but but as a separate class. Registers command on extension activation.
This commit is contained in:
Jakub Synowiec
2017-04-03 19:35:29 +02:00
committed by Matt Bierner
parent 45ab972e3d
commit 70e074ac2f
4 changed files with 60 additions and 19 deletions

View File

@@ -31,5 +31,6 @@
"typescript.referencesCodeLens.enabled": "Enable/disable references CodeLens.",
"typescript.implementationsCodeLens.enabled": "Enable/disable implementations CodeLens. Requires TypeScript >= 2.2.0.",
"typescript.openTsServerLog.title": "Open TS Server log file",
"typescript.selectTypeScriptVersion.title": "Select TypeScript Version"
"typescript.selectTypeScriptVersion.title": "Select TypeScript Version",
"jsDocCompletion.enabled": "Enable/disable auto JSDoc comments"
}