Get more content like this

How to Get Top Performance in Hybrid Mobile Applications - Part 1 of 2

mobile performance banner

Author : Prateek Jadhwani

Mobile app performance is the key to achieving a 5-star rating on application marketplaces like Google Play Store or on the Apple App Store. However, the recent developments in mobile applications and the appearance of sophisticated tools that let teams build a hybrid app in a few minutes have caused developers to forget the term “performance.”

While many companies concentrate primarily on providing mobile app functionalities, here at TechAspect, user experience is given more importance. After all, a user won’t be happy with an app load time of 20 seconds, just to see a login screen.

How to achieve maximum performance in a hybrid application

Understand your target devices

Most of the developers forget the most basic thing - devices!1. Although they know how to classify devices on the basis of the operating systems in use, they never go into the terms like “high-end devices” or “low-end devices.” A small difference in the specification sheet could drastically slow down the app, thus ruining the experience. Designing the app for low-end devices could get rid of 50% of the performance problems caused by CPU-hogging functionalities.

mobile performance devices

Understand your tools

If you have built a Hybrid application, then I am pretty sure you have heard the term “Cordova.” It is an open-source tool that helps you build hybrid applications. Understanding how Cordova works could help you make important architectural decisions. And since it is open source, any one can take a look at its source code.

cordova

Cordova is an open-source tool that helps you build hybrid applications.


Understand core concepts of the languages used to build the app

Small things like an extra div in direct model operations (DOM), an extra string comparison in JS, or an extra shadow property in CSS3 could make a lot of difference 3. Most of the performance problems are visible when the Frame Rates are slow in an app, which will make the app feel sluggish. Understanding how these languages are used to render the app is critical to produce the 60 fps performance required for a smooth experience 8. (Frames per second, or fps, is one of the key parameters used to identify performance bottlenecks.)

Understand the libraries and/or frameworks used

I have seen a lot of people misusing jQuery selectors, 2 also known as jQuery abuse 5 6. Developers forget that they are using a third-party library to make things work. They might be writing a single line of code with the help of method chaining 7 in order to perform DOM operations, but using that code might not always be a good decision. On a desktop, it might be a different case, but when a small device such as a mobile phone runs such operations, it affects both battery and performance 3.

The same considerations apply to frameworks based on model view controllers (MVC). Often, too many templates are used to do a small task. Too many templates mean too many string operations, and string operations are, in and of themselves, a slow operation.

Taking all these coding practices into consideration could reduce the chances of an app creating performance problems.

browser comparison

Performance of cached and non-cached templates in Underscore.js 9


To Know more about on Hybrid Mobile Applications Performance Read More>>

If you would like more help to Get Top Performance in Hybrid Mobile Applications Contact Us Today.

References for Blog Posts in This Series:

1 Android developers forum, Performance focus

2 Addy Osmani, Dev Tools State of the Union

3 Malte Ube, Improving the Performance of your HTML5 App

4 Paul Lewis, Fixing a parallax scrolling website to run in 60 FPS

5 Jeremias Menichelli, Stop the jQuery abuse!

6 Ken Snyder, 5 Common Ways to Abuse jQuery

7 w3schools.com, jQuery Chaining

8 Christian Apers, How to make your apps feel responsive and fast? Part 2

9 Prateek Jadhwani, JSPerformance

Learn more about how TechAspect can help you propel your digital transformation

Get In Touch