不显示带有下划线的Visual Studio Intellisense方法 [英] Visual Studio Intellisense methods with underscore don't appear

查看:197
本文介绍了不显示带有下划线的Visual Studio Intellisense方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VS2012,我的一个项目范围的Javascript函数名称空间的所有公开方法都以下划线 _ 开头,例如:

I'm using VS2012, and one of my project-wide Javascript function namespaces has all of its exposed methods beginning with underscores _, for example:

var NameSpace = {
    _aMethod = function () { },
    _anotherMethod = function () { }
};

我为命名空间创建了一个快速的 vsdoc文件,以及命名空间本身出现,但没有一种方法。注意:如果我在方法的开头删除 _ ,它就像一个魅力。

I created a quick vsdoc file for the namespace, and the namespace itself appears, but none of the methods do. NOTE: If I remove the _ at the beginning of the methods, it works like a charm.

// This would work, and show up in the VSDOC
var NameSpace = {
    aMethod = function () { },
    anotherMethod = function () { }
 // ^ notice no underscores
};

还有这个吗?

通过整个项目并重命名它们(即使使用find-all)也会有风险,因为这些方法与所有内容交织在一起。

Going through the entire project and renaming them (even with a find-all) would be risky since these methods are so intertwined with everything.

推荐答案

如果你进入工具 - >选项 - >文本编辑器 - > JavaScript-> IntelliSense->参考文献,参考组应该有一个下拉列表(取决于你可能的项目类型)需要改变这个)

If you go into Tools->Options->Text Editor->JavaScript->IntelliSense->References there should be a drop down for the reference group (depending on what type of project you may need to change this)

一旦你有了正确的组,你会注意到有一些默认的智能感知参考文件。尝试删除underscorefilter.js

Once you have the right group you'll noticed there are some default included intellisense reference files. Try removing the underscorefilter.js

这篇关于不显示带有下划线的Visual Studio Intellisense方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆