Visual Studio is a great tool but not all tooling is well known. I see this question still way too often on the ASP.NET forums so I thought I would blog about it.
You have a nice -vsdoc.js file sitting in your solution explorer and are used to get that great Intellisense kicking in when you work inside a webpage or webform doing some cool ASP.NET coding.
Figure 1: Solution Explorer showing our –vsdoc.js files
Figure 2: No Intellisense when we expect to see some assistance for jQuery
Of course there’s a solution. And luckily for us, a very easy one:
- Open the .js file
- In the Solution Explorer pick the right –vsdoc.js file
- Drag and drop that in the .js file like in figure 3
- Now try to type $( again and you’ll see like in figure 4 that Intellisense is back again.
- Drink a beer and celebrate (this last step isn’t really necessary but can spice up the fun factor)
Figure 3: Drag and drop from the Solution Explorer into the opened .js file
Figure 4: Intellisense is way back. Woohoo!