2 "name": "coc-tsserver",
4 "description": "tsserver extension for coc.nvim",
5 "main": "lib/index.js",
6 "publisher": "chemzqm",
12 "url": "https://github.com/neoclide/coc-tsserver.git"
20 "prepare": "node esbuild.js"
23 "onLanguage:javascript",
24 "onLanguage:javascriptreact",
25 "onLanguage:javascript.jsx",
26 "onLanguage:typescript",
27 "onLanguage:typescript.tsx",
28 "onLanguage:typescript.jsx",
29 "onLanguage:typescriptreact",
30 "onLanguage:jsx-tags",
32 "onCommand:_typescript.configurePlugin",
33 "onCommand:typescript.reloadProjects",
34 "onCommand:javascript.reloadProjects",
35 "onCommand:javascript.goToProjectConfig",
36 "onCommand:typescript.goToProjectConfig",
37 "onCommand:typescript.openTsServerLog",
38 "onCommand:tsserver.watchBuild"
43 "filetype": "javascript",
50 "filetype": "javascriptreact",
57 "filetype": "typescript",
64 "filetype": "typescriptreact",
73 "title": "Reload current project",
74 "category": "TSServer",
75 "command": "tsserver.reloadProjects"
78 "title": "Open log file of tsserver.",
79 "category": "TSServer",
80 "command": "tsserver.openTsServerLog"
83 "title": "Open project config file.",
84 "category": "TSServer",
85 "command": "tsserver.goToProjectConfig"
88 "title": "Restart tsserver",
89 "category": "TSServer",
90 "command": "tsserver.restart"
93 "title": "Find File References",
94 "category": "TSServer",
95 "command": "tsserver.findAllFileReferences"
98 "title": "Run `tsc --watch` for current project by use vim's job feature.",
99 "category": "TSServer",
100 "command": "tsserver.watchBuild"
103 "title": "Fix autofixable problems of current document.",
104 "category": "TSServer",
105 "command": "tsserver.executeAutofix"
115 "description": "Enable tsserver extension"
117 "tsserver.tsconfigPath": {
119 "default": "tsconfig.json",
120 "description": "Path to tsconfig file for the `tsserver.watchBuild` command. Defaults to `tsconfig.json`."
128 "description": "Sets the locale used to report JavaScript and TypeScript errors. Default of `null` uses english."
130 "tsserver.typingsCacheLocation": {
133 "description": "Folder path for cache typings"
135 "tsserver.formatOnType": {
138 "description": "Run format on type special characters."
140 "tsserver.enableJavascript": {
143 "description": "Use tsserver for javascript files"
145 "tsserver.ignoreLocalTsserver": {
148 "description": "Always use tsserver module from tsserver.tsdk or tsserver extension."
150 "tsserver.maxTsServerMemory": {
153 "description": "Set the maximum amount of memory to allocate to the TypeScript server process"
155 "tsserver.watchOptions": {
157 "description": "Configure which watching strategies should be used to keep track of files and directories. Requires using TypeScript 3.8+ in the workspace.",
161 "description": "Strategy for how individual files are watched.",
163 "fixedPollingInterval",
164 "priorityPollingInterval",
165 "dynamicPriorityPolling",
167 "useFsEventsOnParentDirectory"
169 "default": "useFsEvents"
173 "description": "Strategy for how entire directory trees are watched under systems that lack recursive file-watching functionality.",
175 "fixedPollingInterval",
176 "dynamicPriorityPolling",
179 "default": "useFsEvents"
183 "description": "When using file system events, this option specifies the polling strategy that gets used when the system runs out of native file watchers and/or doesn’t support native file watchers.",
185 "fixedPollingInterval",
186 "priorityPollingInterval",
187 "dynamicPriorityPolling"
190 "synchronousWatchDirectory": {
192 "description": "Disable deferred watching on directories. Deferred watching is useful when lots of file changes might occur at once (e.g. a change in node_modules from running npm install), but you might want to disable it with this flag for some less-common setups."
199 "description": "Directory contains tsserver.js,"
204 "description": "Executable path of npm for download typings"
215 "description": "Log level of tsserver"
217 "tsserver.trace.server": {
225 "description": "Trace level of tsserver"
227 "tsserver.pluginPaths": {
233 "description": "Folders contains tsserver plugins"
235 "tsserver.debugPort": {
237 "description": "Debug port number of tsserver"
239 "tsserver.reportStyleChecksAsWarnings": {
243 "tsserver.implicitProjectConfig.checkJs": {
246 "description": "Enable checkJs for implicit project"
248 "tsserver.implicitProjectConfig.experimentalDecorators": {
251 "description": "Enable experimentalDecorators for implicit project"
253 "tsserver.disableAutomaticTypeAcquisition": {
256 "description": "Disable download of typings"
258 "tsserver.useBatchedBufferSync": {
261 "description": "Use batched buffer sync support."
263 "typescript.showUnused": {
266 "description": "Show unused variable hint."
268 "typescript.showDeprecated": {
271 "description": "Show deprecated variable hint."
273 "typescript.updateImportsOnFileMove.enable": {
276 "description": "Enable update imports on file move."
278 "typescript.implementationsCodeLens.enable": {
281 "description": "Enable codeLens for implementations"
283 "typescript.referencesCodeLens.enable": {
286 "description": "Enable codeLens for references"
288 "typescript.preferences.importModuleSpecifier": {
290 "default": "shortest",
291 "description": "Preferred path style for auto imports.",
292 "enumDescriptions": [
293 "Prefers a non-relative import only if one is available that has fewer path segments than a relative import",
294 "Prefers a relative path to the imported file location",
295 "Prefers a non-relative import based on the `baseUrl` or `paths` configured in your `jsconfig.json` / `tsconfig.json`.",
296 "Prefers a non-relative import only if the relative import path would leave the package or project directory. Requires using TypeScript 4.2+ in the workspace."
305 "typescript.preferences.importModuleSpecifierEnding": {
314 "description": "Preferred path ending for auto imports.",
317 "typescript.preferences.quoteStyle": {
326 "typescript.preferences.useAliasesForRenames": {
329 "description": "Enable/disable introducing aliases for object shorthand properties during renames. Requires using TypeScript 3.4 or newer in the workspace.",
332 "typescript.suggestionActions.enabled": {
335 "description": "Enable/disable suggestion diagnostics for TypeScript files in the editor. Requires using TypeScript 2.8 or newer in the workspace."
337 "typescript.validate.enable": {
340 "description": "Enable/disable TypeScript validation."
342 "typescript.suggest.enabled": {
346 "typescript.suggest.paths": {
349 "description": "Enable/disable suggest paths in import statement and require calls"
351 "typescript.suggest.importStatements": {
355 "typescript.suggest.autoImports": {
358 "description": "Enable/disable auto import suggests."
360 "typescript.suggest.completeFunctionCalls": {
363 "description": "Enable snippet for method suggestion"
365 "typescript.suggest.includeCompletionsForImportStatements": {
368 "description": "Enable/disable auto-import-style completions on partially-typed import statements. Requires using TypeScript 4.3+ in the workspace.",
371 "typescript.suggest.includeCompletionsWithSnippetText": {
374 "description": "Enable/disable snippet completions from TS Server. Requires using TypeScript 4.3+ in the workspace.",
377 "typescript.format.enabled": {
380 "description": "Enable format for typescript."
382 "typescript.format.insertSpaceAfterCommaDelimiter": {
386 "typescript.format.insertSpaceAfterConstructor": {
390 "typescript.format.insertSpaceAfterSemicolonInForStatements": {
394 "typescript.format.insertSpaceBeforeAndAfterBinaryOperators": {
398 "typescript.format.insertSpaceAfterKeywordsInControlFlowStatements": {
402 "typescript.format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": {
406 "typescript.format.insertSpaceBeforeFunctionParenthesis": {
410 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": {
414 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": {
418 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingEmptyBraces": {
422 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": {
426 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": {
430 "typescript.format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": {
434 "typescript.format.insertSpaceAfterTypeAssertion": {
438 "typescript.format.placeOpenBraceOnNewLineForFunctions": {
442 "typescript.format.placeOpenBraceOnNewLineForControlBlocks": {
446 "typescript.format.semicolons": {
449 "description": "Defines handling of optional semicolons. Requires using TypeScript 3.7 or newer in the workspace.",
457 "typescript.suggest.includeAutomaticOptionalChainCompletions": {
460 "description": "Enable/disable showing completions on potentially undefined values that insert an optional chain call. Requires TS 3.7+ and strict null checks to be enabled.",
463 "typescript.workspaceSymbols.scope": {
469 "default": "allOpenProjects",
472 "typescript.autoClosingTags": {
476 "javascript.showUnused": {
479 "description": "Show unused variable hint."
481 "javascript.showDeprecated": {
484 "description": "Show deprecated variable hint."
486 "javascript.updateImportsOnFileMove.enable": {
490 "javascript.implementationsCodeLens.enable": {
494 "javascript.referencesCodeLens.enable": {
498 "javascript.preferences.importModuleSpecifier": {
500 "default": "shortest",
501 "description": "Preferred path style for auto imports.",
502 "enumDescriptions": [
503 "Prefers a non-relative import only if one is available that has fewer path segments than a relative import",
504 "Prefers a relative path to the imported file location",
505 "Prefers a non-relative import based on the `baseUrl` or `paths` configured in your `jsconfig.json` / `tsconfig.json`.",
506 "Prefers a non-relative import only if the relative import path would leave the package or project directory. Requires using TypeScript 4.2+ in the workspace."
515 "javascript.preferences.importModuleSpecifierEnding": {
524 "description": "Preferred path ending for auto imports.",
527 "javascript.preferences.quoteStyle": {
536 "javascript.preferences.useAliasesForRenames": {
539 "description": "Enable/disable introducing aliases for object shorthand properties during renames. Requires using TypeScript 3.4 or newer in the workspace.",
542 "javascript.validate.enable": {
545 "description": "Enable/disable JavaScript validation."
547 "javascript.suggestionActions.enabled": {
550 "description": "Enable/disable suggestion diagnostics for JavaScript files in the editor. Requires using TypeScript 2.8 or newer in the workspace."
552 "javascript.suggest.names": {
556 "javascript.suggest.enabled": {
560 "javascript.suggest.paths": {
563 "description": "Enable/disable suggest paths in import statement and require calls"
565 "javascript.suggest.autoImports": {
568 "description": "Enable/disable auto import suggests."
570 "javascript.suggest.completeFunctionCalls": {
573 "description": "Enable snippet for method suggestion"
575 "javascript.suggest.includeCompletionsForImportStatements": {
578 "description": "Enable/disable auto-import-style completions on partially-typed import statements. Requires using TypeScript 4.3+ in the workspace.",
581 "javascript.format.enabled": {
584 "description": "Enable format for javascript."
586 "javascript.format.insertSpaceAfterCommaDelimiter": {
590 "javascript.format.insertSpaceAfterConstructor": {
594 "javascript.format.insertSpaceAfterSemicolonInForStatements": {
598 "javascript.format.insertSpaceBeforeAndAfterBinaryOperators": {
602 "javascript.format.insertSpaceAfterKeywordsInControlFlowStatements": {
606 "javascript.format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": {
610 "javascript.format.insertSpaceBeforeFunctionParenthesis": {
614 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": {
618 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": {
622 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingEmptyBraces": {
626 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": {
630 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": {
634 "javascript.format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": {
638 "javascript.format.insertSpaceAfterTypeAssertion": {
642 "javascript.format.placeOpenBraceOnNewLineForFunctions": {
646 "javascript.format.placeOpenBraceOnNewLineForControlBlocks": {
650 "javascript.suggest.includeAutomaticOptionalChainCompletions": {
653 "description": "%configuration.suggest.includeAutomaticOptionalChainCompletions%",
656 "javascript.autoClosingTags": {
660 "javascript.format.semicolons": {
663 "description": "Defines handling of optional semicolons. Requires using TypeScript 3.7 or newer in the workspace.",
675 "language": "typescript",
676 "path": "./snippets/typescript.json"
679 "language": "typescriptreact",
680 "path": "./snippets/typescript.json"
684 "author": "chemzqm@gmail.com",
687 "@types/node": "^10.12.0",
688 "coc.nvim": "^0.0.81-next.6",
689 "esbuild": "^0.8.29",
691 "vscode-languageserver-protocol": "^3.16.0",
695 "typescript": "^4.3.5"