Advantages and Disadvantages of JQuery

Lately I experimented with a jQuery occasion calendar on our Reserving System. Our earlier model makes use of ASP.NET to construct the reserving chart as a complete on the server after which renders the lot to the browser. It was a bit sluggish and clunky, however labored.

I wished to have a PHP model of the Room Reserving System so did a fast port from the ASP.NET C # to PHP, after which I dropped the jQuery fullcalendar part on the web page. I used an online service for the info which was nonetheless written in C # in opposition to a Microsoft SQLServer database.

On just a little extra tinkering and refactoring, I discovered I might eliminate nearly all of the PHP / .NET code because it was solely used to initialise the web page. Now I used to be left with a web page with successfully simply HTML and JavaScript utilizing a AJAX to name a JSON knowledge feed from a REST internet service.

The results have been gorgeous! Moreover wanting nicer, the pace of replace was unbelievable – like a Home windows utility. In fact, that is achieved as a result of the web page runs nearly completely within the browser and calendar navigation could request simply small quantity of knowledge utilizing AJAX in opposition to the net service.

May I write the whole utility like this ?

It jogged my memory of programming within the 1990's. Net pages have been HTML with a little bit of JavaScript; we then added just a little ASP to get knowledge from a database and stick that on the web page. Getting knowledge on a web page was comparatively straightforward even then; the issue has all the time been once we need the person to work together with it. Even the easy stuff, like solely permitting a numeric digit right into a textual content field, checking for legitimate date, knowledge grids and even easy popups weren’t as straightforward as in a Home windows app.

Submit why? As a result of pure JavaScript is sluggish to write down, it's straightforward to make errors, troublesome to debug and also you're on the mercy of whichever browser the person has desire for.

Programmers regarded for different means and located them in applets, DLLs, .NET, JSF and different applied sciences and server frameworks. I moved on to ASP.NET as a result of it took the drudgery out of programming, routinely generated the JavaScript and was straightforward to write down and debug; a a lot friendlier mannequin. It nonetheless is, however jQuery and different JavaScript Frameworks at the moment are threatening the established order.

Microsoft has adopted jQuery in a giant manner and it’ll exchange the AJAX Toolkit. Many software program builders have already adopted jQuery or YUI. Mixed with HTML5, these JavaScript Frameworks could pressurise Flash and Silverlight. jQuery actually has a spot within the close to way forward for internet improvement

Can I simply use jQuery and nothing else? Possibly – however not but, not completely. As impressed as I’m with jQuery, I really feel it's simply one of many instruments within the software program developer's toolbox. I'll use jQuery increasingly more however I'll be utilizing.NET and PHP too. Right here's how I summarise it:

For and Towards jQuery and JavaScript Frameworks

FOR:

  • Good Consumer Expertise, near a Home windows GUI
  • A lot simpler to make use of than plain JavaScript
  • Spectacular pace
  • Coders wouldn’t have to fret about Browser variations
  • Reduces Server Load as fewer round-trips
  • Extensively used, good group help
  • Many parts already developed
  • Open Supply

AGAINST:

  • You most likely nonetheless want a Server framework for initialisation and Session administration
  • You want one other app to provide your knowledge (like an online service) written in one other language (like.NET, Java or PHP)
  • In bigger apps, slower to code than PHP or ASP.NET
  • You must perceive CSS
  • Can nonetheless be troublesome to debug, particularly if scripts intervene with one another.
  • Supply code is troublesome to guard
  • Is usually a little cryptic to learn

When you’ve got not tried jQuery then you must undoubtedly achieve this. It's straightforward to get into and can improve your internet functions