jQuery的智能感知VS2010 MVC3 [英] jquery intellisense vs2010 mvc3

查看:103
本文介绍了jQuery的智能感知VS2010 MVC3的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

jQuery的IntelliSense不为我工作,除非我把:

jQuery intellisense does not work for me unless I place:

<script src="../../Scripts/jquery-1.4.4-vsdoc.js" type="text/javascript"></script>

...在页面中。我以为把它在_Layout.cshtml就足够了,但事实并非如此。

...in the page. I thought putting it in the _Layout.cshtml would be sufficient but it's not.

我必须这样做,每一页上,部分等。

I have to do this on every page, partial etc.

这是一个bug或者有更好的方式来实现跨所有页面jQuery的智能感知和.js文件?

Is this a bug or is there a better way to enable jQuery intellisense across all the pages and .js files?

推荐答案

您还可以使用if从句,如:

You can also use an if clause like:

 @if (false) { 
    <script src="/Scripts/jquery-1.4.4-vsdoc.js" type="text/javascript"></script>
 }

这篇关于jQuery的智能感知VS2010 MVC3的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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