VS2010, JQuery and Intellisense
April 21, 2010 Leave a comment
I installed VS2010 this week. I am not sure what took longer – installing 2010 or uninstalling 2008. In any event, I am working on a JQuery project. I was all hot to get JQuery intellisense on a Hello World MVC2 Project. I did file-> New , carved out a Script block, and went to town:
I was immediately confused -> only Javascript intellise. After poking at the problem with Tinu for a couple of minutes, we realized that we need to add in the JQuery Script to get its intellisense
Did the trick
Another problem with JQuery was that some of the selectors were not working. Consider this code block:
$(function () {
$("#sourceTable tr:gt(0)").draggable({
revert: ‘invalid’,
cursor: ‘move’
});
When I fired up IE to see this working, nothing was draggable. I then changed the selector to this:
$("#sourceTable").draggable({
And I had draggability (warning: new word alert) in IE. After banging my head for an hour or so, I accidently clicked on compatibility mode on IE. Low and Behold – it worked! Lesson to the wise – if something doesn’t work as expected, blame IE….
Finally, just so you know – forgot to reference Ajax library, the message box you get is o so helpful:
Finally, really, is a quick reminder to myself about Fiddler: