{"id":1932,"date":"2013-08-13T11:58:56","date_gmt":"2013-08-13T10:58:56","guid":{"rendered":"http:\/\/www.hinnerup.net\/?p=1932"},"modified":"2013-08-15T08:09:24","modified_gmt":"2013-08-15T07:09:24","slug":"problem-with-javascript-intellisense-when-using-resharper-7-and-visual-studio-2012-together","status":"publish","type":"post","link":"https:\/\/www.hinnerup.net\/en\/permanent\/2013\/08\/13\/problem-with-javascript-intellisense-when-using-resharper-7-and-visual-studio-2012-together\/","title":{"rendered":"Problem with JavaScript Intellisense when using Resharper 7 and Visual Studio 2012 together"},"content":{"rendered":"<p>If you are using <a href=\"http:\/\/www.jetbrains.com\/resharper\/\">Resharper 7<\/a> and <a href=\"http:\/\/www.microsoft.com\/visualstudio\/eng\/products\/visual-studio-ultimate-2012\">Visual Studio 2012<\/a> and want to see Intellisense for your JavaScript files you&#8217;re in trouble. Not insurmountable trouble but just enough to waste a few of your precious development hours figurering out a working solution.<\/p>\n<p>I have set up a minimal example where the issue with Reshaper 7 is proven without a doubt.<\/p>\n<p><b>Update 15th August 2013<\/b>: <a href=\"http:\/\/www.jetbrains.com\/\">JetBrains<\/a> has confirmed to me that this is an issue (unimplemented feature) in Resharper and that there are no plans on fixing\/adding it to the tool.<\/p>\n<p>The example is taken directly from Microsoft&#8217;s documentation on how to <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/hh874692.aspx\">Extend Visual Studio 2012 JavaScript Intellisense<\/a> (see the section <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/hh874692.aspx#sectionToggle15\">&#8220;To add an IntelliSense annotation&#8221;<\/a>).<\/p>\n<p>Here you see the three files (demoLib.js, demoLib.intellisense.js and appCode.js) setup in Visual Studio 2012. Visual Studio 2012 and Resharper 7 are both set to their default setting values.<\/p>\n<div style=\"text-align:center\">\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1242.png\" alt=\"Visual Studio 2012, JavaScript Intellisense example 1\" width=\"521\" height=\"436\" class=\"aligncenter size-full wp-image-1933\" srcset=\"https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1242.png 521w, https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1242-300x251.png 300w\" sizes=\"auto, (max-width: 521px) 100vw, 521px\" \/>\n<\/div>\n<p>When you now enter &#8220;<tt>someFunc(<\/tt>&#8221; in the &#8220;appCode.js&#8221; text-editor window you would expect to see the enriched Intellisense popup with function parameter and description data shown. Alas, all you get is this:<\/p>\n<div style=\"text-align:center\">\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1245.png\" alt=\"Visual Studio 2012, missing JavaScript Intellisense with Resharper 7 standard settings\" width=\"333\" height=\"104\" class=\"aligncenter size-full wp-image-1934\" srcset=\"https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1245.png 333w, https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1245-300x93.png 300w\" sizes=\"auto, (max-width: 333px) 100vw, 333px\" \/>\n<\/div>\n<p>Resharper 7 does apparently not integrate with Visual Studio 2012&#8217;s Intellisense design-time script environment, and is thus unable to show the annotated data available through the Visual Studio native JavaScript design-time object &#8220;intellisense&#8221;. To overcome this problem, you need to disable Resharper&#8217;s JavaScript Intellisense: Menu -> Resharper -> Options&#8230; -> Intellisense -> General -> (select) Visual Studio<\/p>\n<div style=\"text-align:center\">\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1249.png\" alt=\"Resharper 7 with Visual Studio Intellisense settings\" width=\"784\" height=\"604\" class=\"aligncenter size-full wp-image-1935\" srcset=\"https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1249.png 784w, https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1249-300x231.png 300w\" sizes=\"auto, (max-width: 784px) 100vw, 784px\" \/>\n<\/div>\n<p>Retrying to enter &#8220;<tt>someFunc(<\/tt>&#8221; in the &#8220;appCode.js&#8221; text-editor window now displays the enriched Intellisense popup with function parameter and description data:<\/p>\n<div style=\"text-align:center\">\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1252.png\" alt=\"Visual Studio 2012, working Intellisense with Resharper 7 Intellisense disabled\" width=\"331\" height=\"151\" class=\"aligncenter size-full wp-image-1936\" srcset=\"https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1252.png 331w, https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1252-300x136.png 300w\" sizes=\"auto, (max-width: 331px) 100vw, 331px\" \/>\n<\/div>\n<p>A &#8220;better&#8221; setting in Resharper 7 would most likely be to disable only Resharper&#8217;s JavaScript Intellisense:<\/p>\n<div style=\"text-align:center\">\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1256.png\" alt=\"Visual Studio 2012 working Intellisense with custom Resharper 7 Intellisense settings\" width=\"786\" height=\"606\" class=\"aligncenter size-full wp-image-1937\" srcset=\"https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1256.png 786w, https:\/\/www.hinnerup.net\/wp-content\/uploads\/2013\/08\/2013-08-13_1256-300x231.png 300w\" sizes=\"auto, (max-width: 786px) 100vw, 786px\" \/>\n<\/div>\n<p>With this setting the native Visual Studio Intellisense continues to work for JavaScript, and you have the added benefit from Resharper&#8217;s augmented Intellisense for other programming languages and file types in Visual Studio 2012.<\/p>\n<p>Enjoy!<\/p>","protected":false},"excerpt":{"rendered":"<p>If you are using Resharper 7 and Visual Studio 2012 and want to see Intellisense for your JavaScript files you&#8217;re in trouble. Not insurmountable trouble but just enough to waste a few of your precious development hours figurering out a working solution. I have set up a minimal example where the issue with Reshaper 7 [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1,8,4],"tags":[104,102,103],"class_list":["post-1932","post","type-post","status-publish","format-standard","hentry","category-misc","category-javascript","category-programming","tag-intellisense","tag-resharper","tag-visual-studio-2012"],"_links":{"self":[{"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/posts\/1932","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/comments?post=1932"}],"version-history":[{"count":6,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/posts\/1932\/revisions"}],"predecessor-version":[{"id":1942,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/posts\/1932\/revisions\/1942"}],"wp:attachment":[{"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/media?parent=1932"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/categories?post=1932"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hinnerup.net\/en\/wp-json\/wp\/v2\/tags?post=1932"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}