views:

61

answers:

4

My team is currently working on a substantial update to an existing ASP.NET 3.5 application which uses the Ajax Control Toolkit on virtually every page. We've found that in many cases that its use is unwarranted (clearly a previous developer decided to "Ajaxafy" everything), and a richer - and simpler - experience can be found using jQuery.

We've also found that the AjaxControlToolkit can be a pain to work with frankly in terms of maintainability and performance when you have half a dozen developers working it. We're debating scrapping its use completely, and going with jQuery for the UI experience. We're fortunate to have enough time to do this safely, and every feature we use can be replicated without any problems (AutoComplete, Calendar Control, etc).

It seems Microsoft are siding with jQuery with its addition to Visual Studio lately, and the current Ajax Control Toolkit isn't in ASP MVC (client side files only). Therefore I'm personally siding with jQuery for the moment, as it seems to have a future, while the Control Toolkit's future is a little more cloudy.

However, from a maintainability perspective, how is jQuery to work with? It's essentially just Javascript, so no plugins required. Are updates stable, and do they often break existing functionality?

+1  A: 

Hey,

The ACT isn't in MVC because the control structure is deeply embedded in the web forms product; most vendors (like Telerik, Component Art etc) are actually writing a separate code-base for MVC because of the complexity of making it work with two frameworks, although Telerik did a good job of it (you can use the web form controls in MVC, though the MVC-specific controls are much nicer to use).

I like JQuery, and for a project, I believe we are going to go Telerik/JQuery and plugins, so that is always a good bet.

Also, the ACT does have a lot of scripts and may not be applicable in all scenarios, but the real issue is adding too much AJAX when it isn't warranted, something that can be a problem with any other framework too.

HTH.

Brian
+1 asp.net mvc + telerik mvc controls are a nice team
redsquare
A: 

jQuery is tested pretty extensively. I don't remember a break caused by an update, you mileage may vary. They would likely know about any compat problems and warn about them in the release notes or elsewhere.

BioBuckyBall
+3  A: 

We use jquery extensively with asp.net 3.5 and have upgrade jquery and jquery ui about 3 times without a hitch. Both times we have had noticeable speed increases. Maintenance has never been an issue in about 2 years of use with 5 developers.

We find jQuery very readable and enjoyable to code with.

Tim Santeford
We've found jQuery is easier for new-to-it developers to grok and get going with than MSAJAX.
dave thieben
+3  A: 

Don't give up on AJAX just yet. Both AJAX and jQuery are useful as long as you're using them to do what they're suited to. I really don't see too much of a difference in maintainability, it's all still code. You need to test new releases/updates before putting them into production; vet any 3rd party code you're integrating into your code base, and make sure that you're not using AJAX/jQuery to pound a square peg into a round hole.

As to the pros/cons of AJAX vs jQuery:

AJAX beats out jQuery when it comes to:

  • Server-Side integration
  • CLR Features and Feel
  • JSON and WCF

jQuery beats out AJAX when it comes to:

  • Animations
  • Being Lightweight
  • DOM Selection
  • Attribute / CSS Manipulation
Jim B
+1 I would agree. With jQuery you tend to need extra hidden fields to communicate back to the server on postback which seems a little clunky.
Tim Santeford
I have never used any hidden fields with mvc+jquery for postbacks. Not sure I understand why the ms js helps out more in this regard.
redsquare