28 thoughts on “VS2010 Tips #7: How to make jQuery Intellisense work for external JavaScript file

  1. Pingback: Tweets that mention VS2010 Tips #7: How to make jQuery Intellisense work for external JavaScript file · Ferry Meidianto -- Topsy.com

  2. Frithjfo

    Nice one 😀

    If someone has the same problem:

    The line generated by the “magic drag drop”
    /// reference path=../pathtofile.js

    must be the first line of the js file, where you want to use intellinsense…

  3. Greg K

    What about:
    (function ($) {
    test = function () {

    };
    })(jQuery);

    is it working inside test function?

  4. Pingback: Using jQuery Intellisense in Visual Studio 2010 | Warren Tang's Blog

  5. vinny

    This doesn’t work for my 🙁 I was really hoping to get some jquery intellisense because we’re using this more and more.

    Any ideas of what could be wrong in vs2010 professional sp1 ?

  6. Lukas

    @Frithjfo: Thank you!
    The references must indeed be the very first lines of the document.

  7. Thomas K. Nielsen

    Perfect thanks. Just what I needed.

    I had some problems dragging and dropping in the ide if anybody else have that problem you need to remember to “check” the option

    tools > options > Text editor > general > Drag and drop editing

    I think it’s “checked” by default, but I might have turned it off and then you cannot drag and drop like that.

  8. Caleb Leak

    Thanks Ferry and also Frithjfo! I also was unable to get this work until I stuck the /// at the top of my file, even before other comments. Works great now.

  9. Pingback: jQuery Intellisense in Visual Studio 2010

  10. PilotBob

    So, how do you keep these up to date as you upgrade your jQuery scripts to newer versions?

    My thought is to modify the file names in my scripts folder to a “non versioned” number and make sure to update those files as I change my script references to new versions.

    BOb

  11. Panoone

    Genius, PilotBob. That’s just what I did. 🙂

    For others who are having difficulty (like I was), as the FIRST line in your custom js file, add the following project RELATIVE reference link to your jQuery file.

    ///

    As PilotBob mentioned, usinga generic name means not having to worry about update issues.

    Just be sure to keep the version number intact in the jQuery file itself for eases of identification.

    /*! jQuery v1.x.x http://jquery.com/ | http://jquery.org/license */

  12. Pingback: How to make jQuery Intellisense work for external JavaScript file in VS 2010 « Trần Quang Trung

  13. Pingback: intellisense with jquery in visual studio 2010 | PHP Developer Resource

  14. Pingback: jquery intellisense visual studio 2010 « Joshua's Snippets

  15. Pingback: intellisense with jquery in visual studio 2010 | Yaker Answers

Leave a Reply

Your email address will not be published. Required fields are marked *