Top 50 Jquery Mobile Interview Questions
Q1. How To Stop Jqm From Auto-improving An Element?
To prevent jQuery Mobile shape enhancing an element surely add statistics-position="none" to the detail. Here is a choose that is the everyday, local element in preference to the custom jQuery Mobile styled model that usually is visible.
Q2. What Is .Bind()?
This is the easiest and quick method to bind occasions. But the problem with bind() is that it doesn't work for elements delivered dynamically that suits the equal selector. Bind() most effective connect events to the cutting-edge factors not future detail. Above that it also has overall performance issues while dealing with a huge selection.
Q3. Explain Why There Are Two Different Version Of Jquery Library?
The production model is pretty beneficial at development time as jQuery is open supply and if you want to change something then you can make the ones changes in production model. But the deployment version is minified model or compressed version so it's far impossible to make modifications in it. Because it's miles compressed, so its length is very less than the production version which impacts the page load time.
Q4. Why Do We Use Jquery?
Due to following blessings:
Easy to apply and research.
Easily expandable.
Cross-browser assist (IE 6.0+, FF 1.5+, Safari 2.0+, Opera 9.Zero+)
Easy to apply for DOM manipulation and traversal.
Large pool of constructed in methods.
AJAX Capabilities.
Methods for changing or applying CSS, creating animations.
Event detection and handling.
Tons of plug-ins for all form of needs.
Q5. Can You Please Explain The Difference Between Javascript And Jquery?
JavaScript is a language While jQuery is a library constructed inside the JavaScript language that helps to use the JavaScript language.
Q6. Tell Me How Do You Stop The Currently-running Animation?
Using jQuery ".Prevent()" approach.
Q7. Where Jquery Mobile Works?
JQuery Mobile works on all famous smartphones and capsules.
Q8. What Are Two Different Version Of Jquery Library?
JQuery library is available in 2 one of a kind variations:
Production
Deployment
Q9. How To Keep The Submit Text From Showing With Jquery Mobile?
Suppose we're running on a internet site that has a publish button and paperwork and such. On this website we the use of jQuery Mobile, however to preserve its stylesheet from interfering we the usage of some jQuery.
JQuery Mobile is doing a unusual element wherein it is printing the price of the button, in this example "Submit", to the web page, despite the fact that underneath it there may be a button underneath it that asserts "Submit" and actually works.
Q10. Tell Me Can We Have Multiple Document.Equipped() Function On The Same Page?
YES. We can have any range of file.Equipped() function on the same web page.
Q11. Tell Me How To Disable Jquery Animation?
Using jQuery belongings "jQuery.Fx.Off", which whilst set to proper, disables all of the jQuery animation. When this is done, all animation strategies will straight away set elements to their final nation when called, as opposed to displaying an effect.
Q12. Explain The Starting Point Of Code Execution In Jquery?
The start line of jQuery code execution is $(record).Equipped() feature that's performed when DOM is loaded.
Q13. Explain .Live()?
This approach overcomes the disadvantage of bind(). It works for dynamically added elements or destiny factors. Because of its negative performance on big pages, this approach is deprecated as of jQuery 1.7 and you must forestall the usage of it. Chaining is not nicely supported using this approach.
Q14. Tell Me What Are The Slow Selectors In Jquery?
Elegance selectors are the gradual examine to ID and detail.
Q15. Explain .On()?
Since stay become deprecated with 1.7, so new approach turned into added named ".On()". This approach presents all of the goodness of previous 3 methods and it brings uniformity for attaching occasion handlers.
Q16. How Does Jquery Mobile Theming Work?
The jQuery Mobile theme machine separates color and texture from structural patterns that define such things as padding and dimensions. This allows topic colors and textures to be described once within the stylesheet and to be blended, matched, and mixed to gain a extensive variety of visible consequences.
Q17. Explain .Delegate()?
The .Delegate() approach behaves in a comparable style to the .Stay() approach, but rather than attaching the selector/occasion information to the record, you may pick where it is anchored and it also supports chaining.
Q18. Tell Me An Example Usage Of Jquery Mobile?
$('div').On('faucet', function(occasion)
alert('You tapped an detail');
);
Q19. Tell Me How To Check Data Type Of Any Variable In Jquery?
Using $.Kind(Object) which returns the integrated JavaScript type for the item.
Q20. Explain Finish Method In Jquery?
The .Finish() approach stops all queued animations and locations the element(s) in their final kingdom. This method become brought in jQuery 1.Nine.
Q21. Can You Please Explain The Difference Between Parent() And Parents() Methods In Jquery?
The fundamental difference is the parent() characteristic travels most effective one level within the DOM tree, in which dad and mom() characteristic seek via the entire DOM tree.
Q22. Explain Jquery.Noconflict?
As different consumer facet libraries like MooTools, Prototype may be used with jQuery and they also use $() as their worldwide characteristic and to define variables. This scenario creates battle as $() is utilized by jQuery and other library as their international characteristic. To conquer from such conditions, jQuery has added jQuery.NoConflict().
JQuery.NoConflict();
// Use jQuery via jQuery(...)
jQuery(record).Equipped(characteristic()
jQuery("div").Conceal();
);
Q23. Why Is Only The First Page Of Multi Page Document Loaded?
JQuery Mobile presently most effective supports loading of unmarried page files via AJAX. To navigate to a multi page record you need to disable ajax on the link by means of including the statistics-ajax="false" attribute.
Q24. Why Html 5 Inputs Look Different Across Devices And Browsers?
JQuery Mobile does not have control over the the UI for most of the more recent HTML5 enter elements like date, color and quantity. The keyboards and pickers furnished are browser-established but will safely fall lower back to a general input if it is not supported. We do practice fundamental border and shade patterns to inputs for those factors so there may be a few visual consistency.
Q25. Can We Include Multiple Version Of Jquery?
Yes. Multiple versions of jQuery can be included in identical page.
Q26. Is It Possible To Use Jquery To Make Ajax Request?
Yes. JQuery may be used for making ajax request.
Q27. Is It Possible To Use Our Own Specific Character In The Place Of $ Sign In Jquery?
Yes. It is viable using jQuery.NoConflict().
Q28. Tell Me Is Jquery A W3c Standard?
No. JQuery isn't a W3C widespread.
Q29. Explain The Use Of Jquery .Each() Function?
The $.Every() feature is used to iterate over a jQuery object. The $.Each() characteristic can be used to iterate over any series, whether it's miles an item or an array.
Q30. Tell Me Is Jquery A Library For Client Scripting Or Server Scripting?
Client side scripting.
Q31. How To Divide A Page Into Parts Using Jquery Mobile?
Pages typically don't have a hard and fast height.
If you put a page or some element on a web page to a hard and fast peak the use of CSS, then you may size things in terms of %.
You'll need to use a bit of Javascript to set the page peak.
Here's one way to get the tool peak:
var viewportHeight = document.DocumentElement.ClientHeight;
Here's another (that I have not tried, however should work) due to the fact jQuery Mobile sets the device top as min-height CSS for the web page. (And assuming you have already got a $page variable with the page.)
var viewportHeight = parseFloat($page.Css('min-top'));
Then, you may:
$page.Top(viewportHeight + 'px');
Q32. Can You Please Explain The Difference Between Jquery And Jquery Ui?
JQuery is the middle library. JQueryUI is constructed on top of it. If you use jQueryUI, you must additionally include jQuery.
Q33. Can You Please Explain The Difference Between .Js And .Min.Js?
JQuery library is available in 2 exceptional variations Production and Deployment. The deployment version is also called minified version. So .Min.Js is basically the minified model of jQuery library file. Both the files are identical as far as capability is worried. However .Min.Js is quite small in length so it loads fast and saves bandwidth.
Q34. What Are The Advantage Of Using Cdn?
It reduces the load out of your server.
It saves bandwidth. JQuery framework will load faster from these CDN.
The maximum vital benefit is it'll be cached, if the person has visited any website online that is the usage of jQuery framework from any of these CDN.
Q35. What Is $('div')?
$('div') : This creates a brand new div detail. However this isn't always brought to DOM tree until you do not append it to any DOM element.
Q36. Tell Me How To Executed Jquery Selectors?
Your ultimate selectors is continually achieved first. For instance, in underneath jQuery code, jQuery will first discover all the factors with elegance ".MyCssClass" and after that it will reject all the different factors which are not in "p#elmID".
Q37. Why We Need Jquery Mobile?
JQuery Mobile is a touch-optimized web framework (additionally known as a JavaScript library or a cellular framework) presently being evolved through the jQuery project group. The improvement focuses on growing a framework like minded with a wide form of smartphones and tablet computers, made necessary via the developing however heterogeneous pill and telephone market. The jQuery Mobile framework is like minded with different cellular app frameworks and structures which include PhoneGap, Worklight and more.
Q38. Which Are The Fastest Selectors In Jquery?
ID and detail selectors are the fastest selectors in jQuery.
Q39. Explain Cdn?
A content transport network or content material distribution network (CDN) is a big distributed machine of servers deployed in more than one records centers across the Internet. The aim of a CDN is to serve content material to cease-users with excessive availability and excessive overall performance.
Q40. Can You Please Explain The Difference Between Body Onload() And Document.Equipped() Function?
Document.Equipped() characteristic isn't like frame onload() feature for 2 reasons.
We can have multiple file.Equipped() characteristic in a page in which we will have only one frame onload characteristic.
Document.Ready() function is called as soon as DOM is loaded in which frame.Onload() function is called while the entirety receives loaded at the page that includes DOM, images and all associated assets of the page.
Q41. Explain The Basic Need To Start With Jquery?
To start with jQuery, one want to make reference of it is library.
Q42. What Is .Empty()?
This method eliminates all of the infant detail of the matched element where dispose of() technique removes set of matched factors from DOM.
Q43. What Is Event.Stoppropagation?
Event.StopPropagation(): Prevents the event from effervescent up the DOM tree, preventing any discern handlers from being notified of the event. For example, if there may be a link with a click technique connected inside of a DIV or FORM that still has a click on method attached, it will save you the DIV or FORM click on method from firing.
Q44. Explain Event.Preventdefault?
The event.PreventDefault() technique stops the default action of an element from taking place. For instance, Prevents a link from following the URL.
Q45. What Is .Dispose of()?
Use .Do away with() when you want to dispose of the element itself, in addition to the whole thing internal it. In addition to the factors themselves, all bound events and jQuery statistics associated with the elements are eliminated.
Q46. Explain Is Jquery Replacement Of Java Script?
No. JQuery isn't a substitute of JavaScript. JQuery is a exceptional library which is written on pinnacle of JavaScript. JQuery is a lightweight JavaScript library that emphasizes interplay between JavaScript and HTML.
Q47. Can You Please Explain The Difference Between Calling Stop(authentic,real) And Finish Method?
The .End() approach is similar to .Prevent(actual, real) in that it clears the queue and the modern-day animation jumps to its cease fee. It differs, however, in that .End() additionally reasons the CSS assets of all queued animations to jump to their cease values, as properly.
Q48. How To Load A Page Using Jquery Mobile?
To load an outside web page, enhance its content material, and insert it into the DOM, use the loadPage method. There are numerous methods and properties that you may set whilst loading pages.
Q49. Can You Please Explain The Difference Between Event.Preventdefault And "return False"?
E.PreventDefault() will save you the default occasion from going on, e.StopPropagation() will prevent the event from effervescent up and return fake will do each.
Q50. What To Do To Select Element Having A Particular Class (".Selected")?
$('.Decided on'). This selector is called class selector. We need to prefix the magnificence name with "." (dot).

