While working with phonegap to build native apps I learn a lot. As you know phonegap or any other tools that used to develop apps with html5 always have bad performance. Here we tips that I learn which can be helpful.
I love jquery and use a lot, for web or any other things, mostly animations, interactions and DOM manipulating. But phonegap jquery animation looks really bad, so first rule for me is never use jquery animation on phonegap, use CSS animations. However that’s not the end, use translate instead of using positions:
transform:translate3d(100px, 100px, 0);
or if you prefer not to use plugin, touchend event should be good enough to prevent this delay.
// do something
… to be continue
Use variables instead of calling the DOM itself,
var someThing = $('.something');
someThing.hide() // show()
Use touch when you want to overflow something within a box.
you can also style the sidebar using webkit sidebar:
If you have more to share, please comment below…