Commit Graph

410 Commits

Author SHA1 Message Date
Matt Bierner
cdaa5f28ef Record when tsserver exits with code or errors 2017-05-18 21:35:15 -07:00
Matt Bierner
b8b81b73b4 add tsserver.debug option 2017-05-18 17:34:58 -07:00
Matt Bierner
6d8e64ee3f Add error handler for reader 2017-05-18 17:34:58 -07:00
Matt Bierner
288968f803 Fix duplicate code ids names being uploaded to ts 2017-05-18 17:34:58 -07:00
Matt Bierner
7c2d2c37eb Mark a few members readonly 2017-05-18 17:34:58 -07:00
Matt Bierner
7d2739bfe4 Remove some unused functions in reader 2017-05-18 17:34:58 -07:00
Matt Bierner
89f1f02286 Use correct reporter instance 2017-05-18 15:20:13 -07:00
Matt Bierner
8dd07034c0 Split reporter out into own file 2017-05-18 15:17:42 -07:00
Matt Bierner
4514ddd180 Add option to exclude unique names from suggestion lists in JS files
Fixes #26595

**Problem**
TS includes all unique names in a file in the completion list for JavaScript files. This is often desirable, but may result in unexpected completions

**Fix**
Add a new option `javascript.nameSuggestions` to filter these suggestions out.
2017-05-16 18:35:07 -07:00
Matt Bierner
17004573e3 Always Show File Names in Symbol Search Results (#26518)
* Fixes #26370

Updates the symbol search results to always display the filename. This feature was previously added to the TS extension specifically, so this change removes that work in favor of a change to the core symbol search experience

* Use dash with filename
2017-05-16 17:00:43 -07:00
Matt Bierner
604248eebd Remove unused Writer type 2017-05-16 13:54:01 -07:00
Matt Bierner
53b18c79e7 Mark some buffersync members readonly 2017-05-16 13:43:27 -07:00
Matt Bierner
8786a903f0 use Switch instead of map for looking up modes 2017-05-16 13:43:27 -07:00
Matt Bierner
bb44d4386b Remove linkedmap 2017-05-16 13:43:27 -07:00
Matt Bierner
613724d43b Add logging of PATH to investigate ATA issues reported in #24961 2017-05-15 21:46:21 -07:00
Matt Bierner
ed16aff923 Use more const 2017-05-15 21:38:50 -07:00
Matt Bierner
99f55b2814 Extract TypeScript logger to own file 2017-05-15 21:35:28 -07:00
Matt Bierner
c1eccca103 Remove unused paramter 2017-05-15 21:24:02 -07:00
Matt Bierner
4f398bafda Prototype of Supporting Additional Language Types for TS Plugins
Fixes #25740

Allows ts server plugins to specify that they support additional languages, such as html. These supported languages are defined in the contributes section of the package.json:

```json
"contributes": {
    "typescriptServerPlugins": [
        {
            "name": "tslint-language-service",
            "languages": [ "html" ]
        }
    ]
}
```

This change allows the TS Plugin in VSCode to send the additional file types to the TypeScript server for processing by the plugin
2017-05-15 17:00:10 -07:00
Matt Bierner
78676ce503 Ensure the default js/tsconfig has content when first created. Fixes #21209 2017-05-12 20:50:36 -07:00
Matt Bierner
f856147a01 Split js and ts setting for references code lens
Fixes #26418

Allows enabling or disabling the references code lenses in either javascript or typescript. Previously, the setting enabled it in both language automatically. Enable the code lenses in ts files by default
2017-05-12 20:26:08 -07:00
Matt Bierner
0d5c9f418b Remove Need for File Extensions in TypeScript Language Definitions (#26413)
Part of #25740

To support TS Server plugins for languages like angular, we will allow extensions to register new langauges for TypeScript to watch. The angular language for example would want ng-html files to also be uploaded to TypeScript for checking

The current language definitions all define both a set of language modes they support and a set of file extensions. The file extension part is unnessiary and may be incorrect depending on how a user sets up their `file.associations` in the workspace. This change removes the extensions part so that we always make use of the language mode
2017-05-11 10:48:48 -07:00
Matt Bierner
9cce34d949 Improve plain text display of jsdocs tags 2017-05-10 16:39:10 -07:00
Matt Bierner
9587f8f379 Further tweaks to jsdoc tag rendering 2017-05-10 16:32:17 -07:00
Matt Bierner
2aa11ada5e Address VSCode component of #26415 2017-05-10 15:52:44 -07:00
Matt Bierner
2c7516672e Cleanup some TS files 2017-05-10 00:03:42 -07:00
Matt Bierner
93e42a5e46 Use for of loop 2017-05-09 21:50:56 -07:00
Matt Bierner
f7306841f6 show jsdoc tags in sig help and for completion items
Fixes #26290

Exposes jsdoc tags such as `@priver` in the signature help and in completion items
2017-05-09 21:27:55 -07:00
Matt Bierner
173fc44723 Support Tags in TS/JS Hover Provider
Fixes #26290

Adds support for displaying documentation tags from jsdoc comments (such as `@private`) in hovers
2017-05-09 20:55:58 -07:00
Matt Bierner
946e7ebb2f Reveal TS Server log file in os instead of opening log in explorer. Fixes #25908 2017-05-09 14:56:24 -07:00
Matt Bierner
e2d6ff6181 💄 2017-05-09 11:43:21 -07:00
Matt Bierner
c94789c509 Add Filename to JS/TS Workspace Symbol Search
Fixes #22357

Adds file name to the workspace symbol results for JS and TS
2017-05-09 11:25:38 -07:00
Matt Bierner
c70f922201 Add Suggestion Provider For TS Directives (#25806)
* Add Suggestion Provider For TS Directives

Adds a new completion provider to suggest typescript comment directives, such as `@ts-check` or `@ts-ignore`

Fixes #25413

* Add descriptions to snippets
2017-05-08 13:23:46 -07:00
Matt Bierner
e8b01da790 Clean Up JSDoc Completion Provider Implementation (#25981)
* Fix JSDoc Completion Provider

**Bug**
89da6ab81f fixed #11944 by changing how enter works in completion providers. Now if the completion exactly matches the current text, pressing `enter` is not captured by the the suggestion widget. Instead it inserts a new line into the editor. This broke the jsdoc completion provider which uses `''` as a placeholder insertion before calculating the actual insertion upon being accepted. This weird behavior is because of a of the current tsserver api

**Fix**
Change the insert text to a single space instead. This seems to fix this issue in my testing.

* Slightly more elegant fix
2017-05-05 12:53:05 -07:00
Matt Bierner
79f9601273 Fix configFileWatcher being disposed of incorrectly 2017-05-04 23:37:05 -07:00
Bradley Meck
d6c61a0e12 Add .mjs to known JavaScript file extensions (#25747)
Also add .es6 in missing places
2017-05-04 16:21:08 -07:00
Matt Bierner
636e3b3cb2 Fix a potential hang when tsserver exits improperly (#25808)
**Bug**
If the TSServer restarts with ongoing requests queued, the new server instance may not properly startup. in the logs, this looks like a series of cancelled request followed by a restart message, and then more cancelled requests of the same series

**fix**
I believe the root cause of this is that the request queue is not properly flushed and the request sequence numbers are not properly reset when starting the new server instance.

Fixes #25807
2017-05-03 09:56:55 -07:00
Andy
36baf609e1 Remove unnecessary parentheses (#25573) 2017-05-01 13:35:35 -07:00
Matt Bierner
db036ea0c7 Log Traces at correct level when TSServer exists as expected. Fixes #25381 2017-04-27 16:11:40 -07:00
Matt Bierner
669b5ecb28 Gate pluginProbeLocations to only global ts installs 2017-04-27 12:06:15 -07:00
Alex Dima
8c82a6c615 Fixes #25437 2017-04-27 12:05:04 +02:00
Matt Bierner
456d58d9c9 Automatically restart TS server when user changes TS versions. Fixes #25431 2017-04-26 22:14:36 -07:00
Matt Bierner
38b4b14fb6 Fix ts server potentially logging unknown error code in some cases 2017-04-26 17:17:32 -07:00
Matt Bierner
c478124471 Log tsserver log file path. Fixes #25490 2017-04-26 16:17:09 -07:00
Matt Bierner
d3e4e45320 Fixes #25468 2017-04-26 15:46:14 -07:00
Matt Bierner
3f930c796d Properly gate type definition and implementation providers for TS changes. Fixes #24548 2017-04-25 14:47:37 -07:00
Johannes Rieken
5f319d4892 finalize progress API, #18066 2017-04-25 12:38:41 +02:00
Matt Bierner
dc0f3ecdb2 Fix VSCode/Extensions for TS 2.3.1 (#25248)
From: https://github.com/Microsoft/TypeScript/issues/15352

TS 2.3.1 introduced a breaking change around checking of generic types. This change tries to fix these compiler errors in the extensions codebase
2017-04-24 16:05:57 -07:00
Matt Bierner
072e2f408b Pass Source and Level For TS/JS Errors (#25167)
**Bug**
All TS/JS diagnostics are currently reported as errors. We also cannot pass a custom source to identify them as coming from a tsserver plugin  such as tslint

**Fix**
Add support for the new fields added in TS2.3.1 that provide this information
2017-04-21 15:41:13 -07:00
Matt Bierner
0e7b49949d Lazily Fetch Supported Code Actions for TypeScript (#25164)
Delay fetching the supported code actions for TS/JS until we actually need them.
2017-04-21 14:58:38 -07:00