TypeScript Version: 2.0.6
Expected behavior: Intellisense on .ts files in Visual Studio Enterprise 2015 to work
Actual behavior: All types not recognized, auto-completion does not work, and 'Go to Definition' does nothing.
Note: Intellisense works fine after reverting to Typescript VS Extension: 2.0.3. There seems to be a change between 2.0.3 and 2.0.6 that breaks Visual Studio 2015 Intellisense entirely for my system.
System:
Visual Studio Enterprise 2015: 14.0.25431.01 Update 3
Typescript VS Extension: 2.0.6
.NET FM: 4.6.0.1586
Node: v6.7.0 (VS configured to use node from 'External Tools' options from C:Program Filesnodejs)
is this the case for all .ts file? an empty project? what version of Windows are you running?
Yes it is the case for all .ts files, for a project that happens to be broken.
OS: Microsoft Windows 10 Home - 10.0.14393v Build 14393
File -> New -> Project -> HTML Application with TypeScript (This works fine. _HTMLElement_ has Intellisense for example)
Although the Angular 2 - Quickstart project that is fairly complex, utilizing the more advanced 2.0 features breaks Intellisense for example. I have a fairly complex project utilizing all the npm @types method of including types. It works just fine in Visual Studios with the 2.0.3 VS Extension. But there is definitely a change between 2.0.6 that breaks something critical. I don't know how to investigate further. Any ideas?
Attached below is an ActivityLog after my Visual Studios Enterprise 2015 reported an error with Typescript VS Extension: 2.0.6 installed on the aforementioned system.
ActivityLog.xml
Hope this helps ^_^
from the log, this looks like a culprit:
<entry>
<record>590</record>
<time>2016/10/27 00:09:07.597</time>
<type>Error</type>
<source>VisualStudio</source>
<description>LegacySitePackage failed for package [Microsoft.VisualStudio.LanguageServices.TypeScript.TypeScriptPackage, Microsoft.VisualStudio.LanguageServices.TypeScript, Version=14.0.0.0, Culture=neutral]Source: 'Microsoft.VisualStudio.ExtensibilityHosting' Description: The Visual Studio component cache is out of date. Please restart Visual Studio.
</description>
<guid>{2FFE45C4-5C73-493C-B187-F2E955FF875E}</guid>
<hr>80131500</hr>
<errorinfo></errorinfo>
</entry>
can you try and clear your MEF cache:
%LOCALAPPDATA%\Microsoft\VisualStudio\14.0\ComponentModelCacheOk, so I went ahead and installed the VS extension: Clear MEF Component Cache
I opened my complex Typescript 2.0 project, and all the types are now working again, using Typescript VS Extension 2.0.6. Seems like that did the trick. Thanks a lot, I can get digging in again. Big fan of the TS team by the way. I've learnt a lot by watching this project grow.
Note: I did not have to do the following step to get Intellisense working again, I just used the extension above:
- Re-install Typescript VS Extension 2.0.6
- Delete %LOCALAPPDATA%MicrosoftVisualStudio14.0ComponentModelCache
Thanks for confirming, and for the kind words. Did you have VS open when you first installed 2.0.6?
I generally try to close all instances of Visual Studio before installing extensions from an external installation package. I uninstalled and reinstalled the TS VS extension a couple of times, hopping back and forth between 2.0.3 and 2.0.6. It was strange, 2.0.3 always seemed to have worked in bringing Intellisense back, Although, 2.0.6 never worked once until you mentioned clearing the MEF Component Cache.
I am having a similar problem. Intellisense does not work. I am working with Angular 2 as an FYI.
@IsaacBorrero, we would appreciate additional information.
Most helpful comment
from the log, this looks like a culprit:
can you try and clear your MEF cache:
%LOCALAPPDATA%\Microsoft\VisualStudio\14.0\ComponentModelCache