I am developing a Mobile template for my custom php based website using JQuery Mobile.
After developing few pages, when I tested the system in my and my friend's Android Mobiles and Tabs, I realized that it is running hell slow. I mean, its running slower than the desktop version of the website !!! Sometime it loads, sometime it doesn't. Sometime the links open, Sometime doesn't. Sometime it gets stucked at the loading.
Too too slow, out of the box, but running fast using my UtilForker class (to make pagebeforeshow and several other lifecycle event methods asynchronous) Hey yes, of course I can make those events asynchronous if the duration of my transition is greater than the amount of milliseconds necessary to process the method business content >> Very very efficient when the lifecycle function content is not blocking the startup of the jquery transition management process :-)
PS: JQuery 1.0 is running much more faster than 1.1 and < on ios 6.
You're totally missing the point made by watusiware. If you want to cache references to an element, then use a simple variable for frequently accessed objects instead of inventing an extra unnecessary caching layer. jQuery Mobile loads documents into the DOM via AJAX and you don't need an extra caching layer just to access elements in an efficient manner.
Except that UtilDom garantees the same reference in the whole application...
Not sure what your point is. So can standard variables... UtilDom is really just an object array variable with additional lookup overhead on top of it. So, instead of just storing the item once in a variable and reusing it directly, one has to go through the extra logic of UtilDom.get() every time to check to see if the reference already exists. I'd rather just look up the element once, store it in a variable, and reuse it directly every time I need it than call a function that adds additional logic to check to see if the reference already exists in an array.
Based on your response I'm not sure you truly understand how references can be cached using regular ol' variables instead of adding the overhead of yet another library/utility. I'll use the basic capabilities of the core language over an unnecessary library any day... That's guaranteed to be faster.