jQuery vs javaScript and samples

jQuery is the wrapper on JavaScript. Meaning jQuery is the wrapper for the raw DOM objects returned by JavaScript.

Since we get jQuery object bag, so we could use methods like css, etc., These methods are not available on the raw DOM object.

document.getElementById('id') is faster than $('#id'). So use javascript, when there is simple work like using css or retrieving values.

And use jQuery, if there is any complex functionality is involved and to use minimal coding.
Also this is easy for the developers


Comments

Popular posts from this blog

Unable to deploy wsp pacakage - Timer job and cache issue

Volatile function error for SharePoint calculated field current date

Search not working in federated SAML authentication SharePoint site