Visual Studio 2010 intellisense for KnockoutJS inside RequireJS

老子叫甜甜 提交于 2019-12-07 13:13:27

问题


I want to get intellisense, inside Visual Studio 2010, for knockoutJS.

What I have after some research is:

///reference path="../lib/knockout/knockout-2.3.0.debug.js" />  
ko.WeGotIntellisenseHere; //As long as we don't add RequireJs intellisense reference above knockout reference

define(['jquery', 'knockout'], function($, ko){
    ///<param name="ko" type="knockout">
    ///some comments
    ///</param>
        ko.NoIntellisenseHere(); // unless I change "type=knockout" by "type=Array"
});

Do you know if maybe the "type=knockout" is not correct??? When I change to "type=Array", intellisense works both outside (showing knockout members) and inside (showing Array members) of the "define" function

Same thing happens for jQuery

Note: In the example, I'm not writing the opening tag chracter "<" for the "reference" tag because it has problems on SO

Thanks in advance

来源:https://stackoverflow.com/questions/22561756/visual-studio-2010-intellisense-for-knockoutjs-inside-requirejs

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!