Posts

Is React Native a good choice for developing consumer or business mobile app?

Well ! As the ways of developing an app are changing these days, it provides useful and user-centric apps to businesses and organizations for improving their business presence through a mobile app. These all changes are possible due to the presence of various cutting-edge tools, platforms, and frameworks. These all things have brought ease and convenience for developers and designers to create incredibly potential mobile apps. The React Native is one of the new entrances in the mobile app development platform. It is a cross-platform app framework created by Facebook. It allows developers to use JavaScript in order to create mobile apps for both Android and iOS that look, feel, and are native.

React Native enables you to build world-class application experiences on native platforms using a consistent developer experience based on JavaScript and React. The focus of React Native is on developer efficiency across all the platforms you care about – learn once, write anywhere. So in few words, we can define ReactNative as:

  • It is a framework for mobile development
  • Responsible for building native mobile application
  • Provides basic set of components for mobile platforms
  • Uses ReactJs to build mobile app components

Benefits of React Native

There are many advantages for using React Native Framework but most effective are listed below

  • Code Reusability: Allow you to write some basic UI code that can be shared together with all the logic. Having the capacity to share the code is in good interest for many reasons like- better usage of human resources, less code to maintain, less possibility of bugs and much more.
  • Effective Developer Experience: With React Native it is not necessary to re-compile the entire rebuilt application every time you make a change, simply choose Cmd+R and refresh, like refreshing the browser to reflect the changes saving a lot of re-compilation time.
  • Declarative API: It allows you to consider only the current UI state without keeping track of the older ones.
  • Easy Reloading: It removes the need for recompilation of the application each time a change has been made. All that is required to see changes implemented in the code, is to refresh the app in the simulator, emulator, or device.
  • Cross Platform: It means that you need to write the code once and use it on multiple platforms like iOS, Android etc.
  • Open Source: It is open source and so, there is a big community of developers helping to implement more features, fix bugs, and help people.

Benefits of Native App

Native apps are smartphone applications written specifically for a particular device. iPhone apps are written in Obj-C or Swift while Android apps are written in Java.

  • Faster: Since native apps work with the device’s built-in features, they are easier to work with and also perform faster on the device.
  • Quality: While other methods can achieve greatness, native applications have the opportunity to be set apart. Greater chance your app will not get rejected due to poor user experience because the native app uses their native hardware’s feature to run the app.
  • Aspect Ratio: Apps developed for tablets can’t be used for phones and vice versa. Not just the aspect ratios are different, but dpi also vary from one device to another. All these differences can completely change how should an app look and workUsing Obj-C or Java gives you more control on the size, resolution and even orientation.
  • Native Look and Feel: We love being at home. Your application feels like it belongs to your device. Native apps feel and look like default apps, and users quickly get used to specific icons and button. Mobile apps that try to produce that old look again often appear worse because of unnatural valley effect.

Native or React Native?

Every framework has their pros and cons like – As React Native is new, it is not very perfect yet and it still has some bugs. There are still some features that are available in the native frameworks that have not been exposed to React Native.So, sometimes, developers can be stuck when diving deeper. On the other hand, Native is time-consuming and more costly due to high maintenance of multiple code bases. It may require more developers with experience in each framework to maintain.

In order to decide if you want to develop a native app or React Native app, you need to consider the following points:

  • your existing coding skills,
  • the purpose of your app,
  • the longevity of the project.
  • How important speed and performance would be, to you
  • If you would like your app to include any device-specific features
  • Your budget, vs. the estimated cost of developing your app

Conclusion

Though, React Native is following the write once and run anywhere, it would be proved to be a successful solution if you are building an app for any social group, eCommerce business etc. but, not any graphic specific app like- game because it can make your app slow and less responsive.

So, if you are new in the mobile development, I would recommend you to start with android native instead of React Native if you want to particularly develop android apps. As it will help you to understand the background knowledge of the Android which is required for any android app development otherwise you can be stuck in some problems which are related to the underlying platform. Especially, when your app targets many android API versions. I hope this article helped you in deciding which platform will suit you most for your app development. 🙂

If you are looking for React native developer with great experience please contact us at iPragmatech. We provide end to end Software Development based on the latest technologies back by unique quality management systems to provide complete client satisfaction. Clear communication, dedicated support, prompt response and on-time delivery of solutions within the budget are the main USP of our company.

If you are interested in designing a mobile app, please get in touch with us.

Here are our Contact Details:

References

React Native

Facebook React

Further Reading

AWS Mobile SDK – The quickest way to build a AWS mobile app

The AWS Mobile SDK makes it easy for the app to directly access AWS services such as Amazon Lambda, S3, DynamoDB, Mobile Analytics, Machine Learning, Auto Scaling, etc. It supports iOS, Android, Xamarin, React Native, and Unity apps. In this article, we are mainly going to discuss steps to build AWS mobile app for Android using AWS Mobile SDK. The AWS Mobile SDK for Android is an open-source software development kit distributed under the Apache Open Source license. Amazon Web Services(AWS) is a Cloud services platform which provides a simple way to access servers, storage, databases and a broad set of application services over the Internet. It also owns and maintains the network-connected hardware required for these application services, while you provision and use what you need via a web application.

Steps to use AWS Mobile SDK in your Android mobile app

Step 1: Include the SDK in your AWS mobile app

There are two options to include the AWS mobile SDK in your project:

Option 1: Importing .jar file in the project from the link- Mobile SDK. Now you can drag .jar files for the individual services your project will use into the apps/libs folder. They’ll be included on the build path automatically. Then, sync your project with the Gradle file.

Option 2: Importing gradle file into your Gradle.

    dependencies {
        compile 'com.amazonaws:aws-android-sdk-core:2.2.+'
        compile 'com.amazonaws:aws-android-sdk-s3:2.2.+'
        compile 'com.amazonaws:aws-android-sdk-ddb:2.2.+'
    }

You can compile as much file your project needs. Then now sync your gradle.

Step 2: Set permission in your Manifest file of project

Add the following permission to your AndroidManifest.xml

    <uses-permission android:name="android.permission.INTERNET" />

Step 3: Get your AWS Credentials

Now the next step is to create an account in your AWS console. After creating an account in AWS Console you will get your authentication credentials. You can use it to access your AWS data in your app. For example, to access your EC2 like below:

   AmazonEC2Client ec2Client = new AmazonEC2Client(getCredentials());
   DescribeInstancesResult eC2value = ec2Client.describeInstances();
   DescribeRegionsResult eCRegion = ec2Client.describeRegions();

Here getCredential() method returns the credentials provided by you to authenticate yourself. If the credentials will be authenticated you will get EC2 data otherwise it will throw an exception. In the same way, you can retrieve the other AWS resources like S3, DynamoDB, RDS etc.

You can also obtain AWS Credentials using Amazon Cognito Identity as your credential provider. Using a credentials provider allows your app to access AWS services without having to embed your private credentials in your application. This also allows you to set permissions to control which AWS services your users have access to.

To use Amazon Cognito, you must create an identity pool. An identity pool is a store of user identity data specific to your account. Every identity pool has configurable IAM roles that allow you to specify which AWS services your application’s users can access.

Conclusion

There are various advantages and benefits of AWS like- Trade capital expense for variables expense, benefit from massive economies of sales, increase in speed and agility etc. So after looking these all benefits having a mobile app to access the AWS resources can be proved to be very helpful and important. To use the AWS Mobile SDK in your AWS mobile app is quite easy. I hope this article would help to start your project to use AWs data in your app :-).

References

AWS : It features various types of resources to help us learn about the services and features AWS has to offer and get started with building our solutions faster.

AWS Mobile SDK: It includes libraries, code samples, and documentation for different mobiles platforms so we can build apps that deliver great experiences across devices and platforms.

Further Reading

How to fix html5 file input issue in cordova android app?

Have you got an issue while using Cordova html5 file input i.e not able to access the camera or gallery on your android mobile app or click on the file input is unresponsive? If the answer is yes, then congrats you are not alone we faced this issue too 😉 . Recently we were working on one of our client’s project and they wanted to launch their responsive website on Android and IOS platform. As their site is mobile responsive so we decided to use Apache Cordova platform to launch the mobile app for it.

As a dream, all things were perfectly on iOS platform till we hit the wall for Android platform. The issue was related to opening the Camera or Library option to upload the picture for user’s profile. It seems a very trial issue and we thought we could resolve it in few hours but we got to know how complex it is when tried to solve it 🙁 .

Issue Description

On the website, we used html5 file input i.e <input type=”file”> to open the link to choose the photo from the phone gallery or Camera. Normally at this point, a dialogue would open allowing the user to select an image from the gallery or take a picture on iOS app but clicking on the “Choose Photo” button does nothing on the android app. We were clueless as there were no errors on log cat or chrome’s console.

What was the exact issue?

This is an external issue in the Google Chromium web view. Also, InAppBrowser default plugin this functionality doesn’t exist. More information about this is available here:

Tried multiple ways to resolve the issue

First, we thought that issue would we easy, may be some permission is missing because it was working fine on IOS. So we changed the permission for all but the result was same as before i.e no action. Then we explored more find the following options to solve the issue:

  • We used CrossWalk one of the popular solutions suggested by many developers. Basically, it is replaced the android webview with Crosswalk, but we got no answer 🙁 .
  • We also tried Cocoon. It provides all the tool and services to create and configure our project. We build our app over there and run it on our mobile. It provides a various Webview engine to use, powered by Cordova such as Canvas+ a webview especially for a game, Webview a simple engine to run our app and the Webview+ which is a webview engine designed their own. So we ran the app on the Webview and again the result was same without any change. Next, we used Webview+ to run the app and surprisingly it works. As Webview+ was their own plugin for webview engine so we tried to implement their WebView+ plugin, but we were not able to do same because it has been discontinued and there is such solution for the latest version.

So, above is all about the issue and its possible solution provided.

Possible Solutions

There is no verified and complete solution available. Below are some suggested solutions for the issue:

  • We can use the camera plugin provided by InAppBrowser, but in that case, we have to do some changes on server side. We will need to add cordova plugin on the server side.
  • Change the code of InAppBrowser class in your project. In this class, you need to do some implementation as suggested in the link.

Actually, above change in code will help you to access the file on mobile greater than 4.4 version of Android. It isn’t really a Cordova InAppBrowser bug, it’s an android 4.4 webview bug. The problem is cordova is based on the webview, so the bug extends to cordova. The Android 4.4 won’t include a browser and the device vendor will have to create their own browser using a webview, that means any browser apart from chrome will have <input type=”file”> working.

It affects chrome and any other app that tries to get an URL from the result of an Intent.ACTION_GET_CONTENT ). The problem here is the file picker isn’t even called because overwriting openFileChooser private function isn’t working on android 4.4 the file picker is opened on chrome and chromium, but not on the webview. The Cordova html5 input type file button does generate an onClick event. So anyone can write js to respond to that event. But the value property of the type=”file” input object in the DOM is read-only in js, so it isn’t possible to set it from js. That is for security reasons.

So if it is not possible to set the input value via js, and openFileChooser() in CordovaChromeClient no longer gets called so we never get a handle to the ValueCallback. This means there is no way for Cordova html5 input type file to be used to store the result from a picker.

Conclusion

Apparently, html5 file input i.e <input type=file> is even causing trouble for android phone because InAppBrowser doesn’t support the functionality . There’s no quick fix we can use, so will need to hack it up if we want to make it work. Likely it will be fixed in a future update.

If you liked this post and want to know more or need any help, please contact us at : [email protected] and WhatsApp no : +91-880 046 6470  or visit us at: ipragmatech.com

References

CrossWalk :  The Crosswalk Project is an HTML application runtime, built on open source foundations, which extends the web platform with new capabilities.

Cocoon:  The Cocoon framework provides all the tool and services to create and configure a native HTML5 app and games with a simple workflow and all the power of Cordova.

Github : This link will help you to make changes in your code with explanation.

 

For further reading :

How to validate payment through PayPal using Magento REST API ?

In this digital age to maintain your business growth, Mobile application for your eCommerce becomes the main key point in short mCommerce. Data researched by Coupofy suggests that between 2013 and 2016 mobile shopping will grow 42% compared to regular eCommerce’s 13%, and mobile users will spend a total of $600 billion in 2018, a 300% growth from 2014’s $200 billion. Business owners are focusing on launching their mobile app to make their exists in this digital age. So the development of mCommerce is in the pick point now. As the mCommerce Mobile application development growing rapidly there are a lot of issues are in the queue related to design, performance, UI, payment gateway, validate PayPal payment etc. In this article, we are going to discuss how to validate PayPal payment through Magento REST API interface?

So what is the actual problem?

We are developing an android app for Magento base eCommerce site. We are using REST API. Payment and order related things integration is challenging for us, since we need more secure and careful module development. We are doing an android app so there is a situation where we have complete the payment process using PayPal express mobile SDK. In return, we get transaction id, according to my understanding we have to save with the created order. In the site, we configured PayPal successfully. So the transaction id passed to Magento, where we need to validate PayPal payment. Now at the end, we want an API from Magento side to save the transaction and complete the checkout process.

In fact lot of people have the same problem:

Solution

We have gone through the answer posted in the various community like StackExchange, Magento forum etc. After a little bit research, we have to use the following approach and quite suited well to our requirement.
1. Created a custom payment Method: In the box, Magento rest api does not support place order without the payment method. We have created a custom payment module with a custom method. For More detail how to create a payment module check here. Here is the code sample for our method:

/**
 * Copyright © 2016 iPragmatech. All rights reserved.
 */
namespace Ipragmatech\Paymentapi\Model;

/**
 * Pay In Store payment method model
 */
class Ippaypal extends \Magento\Payment\Model\Method\AbstractMethod
{

    /**
     * Payment code
     *
     * @var string
     */
    protected $_code = 'ippaypal';

    /**
     * Availability option
     *
     * @var bool
     */
    protected $_isOffline = true;
}

2. Enable only for the rest API: The above method enables only for the rest api and not supported on the web app for the payment. Make a new rest api endpoint to receive the transaction id and validate it from PayPal. After successful validation move to the next step.Check out the documentation to validate PayPal payment.
3. Saved transaction id with order: Once all validation are passed save the transaction id return by the PayPal with the order. A transaction is a proof that payment has been done. In Magento transactions are created when the invoice is created, although Magento creates the transaction by itself you don’t need to worry about that but in case you will have to create the transaction manually, here is the code snippet that will create a transaction:

public function createTransaction($order = null, $paymentData = array())
    {
        try {
            //get payment object from order object
            $payment = $order->getPayment();
            $payment->setLastTransId($paymentData['id']);
            $payment->setTransactionId($paymentData['id']);
            $payment->setAdditionalInformation(
                [\Magento\Sales\Model\Order\Payment\Transaction::RAW_DETAILS => (array) $paymentData]
            );
            $formatedPrice = $order->getBaseCurrency()->formatTxt(
                $order->getGrandTotal()
            );
 
            $message = __('The authorized amount is %1.', $formatedPrice);
            //get the object of builder class
            $trans = $this->_transactionBuilder;
            $transaction = $trans->setPayment($payment)
            ->setOrder($order)
            ->setTransactionId($paymentData['id'])
            ->setAdditionalInformation(
                [\Magento\Sales\Model\Order\Payment\Transaction::RAW_DETAILS => (array) $paymentData]
            )
            ->setFailSafe(true)
            //build method creates the transaction and returns the object
            ->build(\Magento\Sales\Model\Order\Payment\Transaction::TYPE_CAPTURE);
 
            $payment->addTransactionCommentsToOrder(
                $transaction,
                $message
            );
            $payment->setParentTransactionId(null);
            $payment->save();
            $order->save();
 
            return  $transaction->save()->getTransactionId();
        } catch (Exception $e) {
            //log errors here
        }
    }

Click here more detail regarding the transaction.

Conclusion

After all, we have used this approach to validate payment because this is well suited to our requirement. If you have a better idea please fell free to share in the comment. This might help a lot to us as well others.

Reference

Twilio voice: Receive Call On Your Android Mobile

Twilio voice is a telephony web-service API that lets you use your existing web languages and skills to build voice and SMS applications. Twilio is a third-party service. Here we have easy steps to receive call using android twilio voice.

Twilio Voice allows your applications to make and receive phone calls. Twilio SMS allows your applications to make and receive SMS messages. Twilio Client allows your applications to enable voice communication using existing Internet connections, including mobile connections.

Building Apps That Talk in the Cloud

Using Twilio Client for Android, developers have access to a few key features that will make building communications apps easy.

  • Real-time Presence – Build buddy lists into any app letting users know who is online and set up notifications when a user is available for voice chat
  • App Backgrounding – The SDK can receive voice calls even when a different app is in use, letting users switch between apps easily to respond to incoming calls.
  • Cross-Platform Interoperability – Twilio Client supports Android, iOS, and web browsers so apps can make calls between any platform, including bridging VoIP calls with traditional phone calls.
  • Voice Over Data and WiFi connections – Make and receive calls over data and WiFi connections without using carrier minutes.

Steps to make call in android Twilio voice

Step 1: Configure your application to use twilio libraries

import com.twilio.client.Connection;
import com.twilio.client.ConnectionListener;
import com.twilio.client.Device;
import com.twilio.client.DeviceListener;
import com.twilio.client.PresenceEvent;
import com.twilio.client.Twilio;
private static final String TOKEN_SERVICE_URL = "your twilio url";

Step 2: Initilizze the twilio sdk

if (!Twilio.isInitialized()) {
    Twilio.initialize(getApplicationContext(), new Twilio.InitListener() {

        /*
         * Now that the SDK is initialized we can register using a Capability Token.
         * A Capability Token is a JSON Web Token (JWT) that specifies how an associated Device
         * can interact with Twilio services.
         */
        @Override
        public void onInitialized() {
            Twilio.setLogLevel(Log.DEBUG);
            /*
             * Retrieve the Capability Token from your own web server
             */
            retrieveCapabilityToken(clientProfile);
        }

        @Override
        public void onError(Exception e) {
            Log.e(TAG, e.toString());
            Toast.makeText(ClientActivity.this, "Failed to initialize the Twilio Client SDK", Toast.LENGTH_LONG).show();
        }
    });
}

Step 3: In this step generate Capability tokens. Capability tokens allow you to add Twilio capabilities to web and mobile applications without exposing your super secret Auth Token in JavaScript or any other client-side environment.

  • Your server provides a Capability Token to each client.
  • Each token contains specific information that enables Twilio to identify that the client belongs to your Twilio account, and what permissions (‘capabilities’) you have granted this user.
Uri.Builder b = Uri.parse(TOKEN_SERVICE_URL).buildUpon();
if (newClientProfile.isAllowOutgoing()) {
    b.appendQueryParameter("allowOutgoing", newClientProfile.allowOutgoing ? "true" : "false");
}
if (newClientProfile.isAllowIncoming() && newClientProfile.getName() != null) {
    b.appendQueryParameter("client", newClientProfile.getName());
}

Ion.with(getApplicationContext())
        .load(b.toString())
        .asString()
        .setCallback(new FutureCallback<String>() {
            @Override
            public void onCompleted(Exception e, String capabilityToken) {
                if (e == null) {
                    Log.d(TAG, capabilityToken);

                    // Update the current Client Profile to represent current properties
                    ClientActivity.this.clientProfile = newClientProfile;

                    // Create a Device with the Capability Token
                    createDevice(capabilityToken);
                } else {
                    Log.e(TAG, "Error retrieving token: " + e.toString());
                    Toast.makeText(ClientActivity.this, "Error retrieving token", Toast.LENGTH_SHORT).show();
                }
            }
        });

Making an HTTP request to the /token endpoint of the web-server returns a Capability Token, which, when provided to a Device constructor, grants the new Device capabilities such as making outgoing calls or allowing incoming calls.

Conclusion

If you want to implement android twilio voice call in your project then you will find these steps more easy. Implementation of android twilio voice has very easy steps as described above. You can edit the xml and activity files in your own way to make it more attractive as per your requirements.

Go to Call android using twilio voice Example on Github

Refrences

Twilio : Twilio documentation that gives the information about twilio.

Android : Android document that gives the information about android that is useful for developer.

Top 9 reasons why you should upgrade in android 7.0?

An open source ,Google’s backing, the app ecosystem are some of the important factors which have made the Android OS by Google to reach its current dominant position in the mobile OS market. Recently, Google came with new features in android nougat with considerable changes in design after Android 6.0- Marshmallow version. Android 7.0 Nougat introduces a variety of new features and capabilities for users and developers.

Best features in android 7.0

1. Multi-window Support : 

Sometimes when you’re doing two things at once it’s handy to be able to see them both at the same time. That’s what Multi-window is: more than one “window” on your phone’s screen. We’ve seen a similar feature with the same name from Samsung (and to a lesser extent LG) for a while, but Google has built things in a way that any app will just work, without the developer — or you — doing anything special. The screen will be split 50/50 by default, and it’s quick to pull up different apps on the top and bottom on a phone or left and right on a tablet.

2. Notification Enhancement :

With Android Nougat, you can reply to your notifications directly from their spot in the tray. You won’t have to open the app or install anything extra, either. Once the folks who built your app support the feature, it will just work.

Don’t worry though. When you need to see more or do more than just send a quick reply, you can still tap the notification to open an app and see everything. And with better bundling of multiple notifications from the same app, you’ll be able to tell when you need to see everything even easier.

3. New Emojis : 

In addition to 72 new glyphs, Android 7.0 has over 1,500 emoji, many of which have been revamped to look a bit more…. human. Traditionally, Android emoji have been cartoony, which has encouraged other manufacturers like Samsung and LG to write their own.

4. Quick settings tile API :

Quick Settings is a popular and simple way to expose key settings and actions, directly from the notification shade. Android 7.0 expanded the scope of Quick Settings to make it even more useful and convenient. Added more room for additional Quick Settings tiles, which users can access across a paginated display area by swiping left or right. For developers, Android 7.0 also adds a new API that lets you define your own Quick Settings tiles to give users easy access to key controls and actions in your app.

5. Number Blocking :

Android 7.0 now supports number blocking in the platform and provides a framework API to let service providers maintain a blocked-number list. The default SMS app, the default phone app, and carrier apps can read from and write to the blocked-number list. The list is not accessible to other apps.

By making number blocking a standard feature of the platform, Android provides a consistent way for apps to support number blocking across a wide range of devices. Among the other benefits that apps can take advantage of are:

  • Numbers blocked on calls are also blocked on texts
  • Blocked numbers can persist across resets and devices through the Backup & Restore feature
  • Multiple apps can use the same blocked numbers list

Additionally, carrier app integration through Android means that carriers can read the blocked numbers list on the device and perform service-side blocking for the user in order to stop unwanted calls and texts from reaching the user through any medium, such as a VOIP endpoint or forwarding phones.

6. Improved security :

Keeping your data private and personal is important. New features in Android Nougat make things even more secure. When you start your phone, some apps are able to partially work before you sign in with your password or PIN. Things like the actual phone app or your text messages can still come in, your alarm will still work and any accessibility features needed to better interact with your phone can still run. Other apps and their data will remain unavailable and/or encrypted. Once you sign in, everything will work normally.

This feature helps keep your data safe if your phone gets lost or stolen, and synergizes well with the remote features of Android Device Manager.

7. Android TV recording and Picture in picture :

Basic DVR functionality is coming to Android TV with 7.0. Besides basic controls like Play or Rewind, you’ll be able to save multiple sessions. This means you can schedule recordings or record as you watch.

This should be a great feature for Televisions that come with Android TV installed.

8. Android for work :

If you use your personal Android phone on the job through a managed system, changes are coming.For us, things will mostly look and act the same — but better tools and easier ways to set things up mean your IT guy might not be so busy (or so grumpy) and everyone’s information will be safer and more secure.

The things we could see, like not being able to use an app we love on company time or being forced to a certain network, depend on what your company needs and how they have things set up. Be sure to go over any questions with your hopefully less-grumpy IT guy if you have them.

9. Language and Locale :

If you have your phone set for a specific region — let’s say the French-speaking portion of Switzerland — your phone will now try to use a similar region setting if it can’t find a specific match. In our example, that means an app can display text and numerical data for standard French instead of just using the default language settings if Swiss localization wasn’t included.

You can also select multiple languages (or regionalizations of the same language) in an order of importance — if an app you’re using is localized for multiple languages you’ll see your top pick — if it’s set up for one but not all of your languages, it’ll pick the highest one it can.

Conclusion

These are the features of android nougat. The largest change in Android 7.0 is to the overall design philosophy of the Operating System. These are the good changes for better performance, stability and battery life. It has made the Design more cohesive. These features of android nougat make different from other android versions. These features were not available in android marshmallow.

References

Android Nougat : Description of android for Developers.

Top android libraries every android developer should use

Android market is growing day by day. Android has a vibrant and strong ecosystem of open source android libraries that developers can freely use in their own apps. It may sound like a lot of work to use an open source library in a project, but with Android Studio, it’s easier than ever. Often it only takes one line of code in your app’s build.gradle file to include a library automatically. Gradle is the new build automation tool in Android Studio, and it will automatically download and include libraries if they are set up for it. It is so easy and popular that many libraries have this built in and include instructions on how to do it. Here we explain the top android libraries that will make your app more attractive.

Top android libraries every Android Developer should use

1. Networking 

  • Retrofit : Retrofit is the class through which your API interfaces are turned into callable objects. By default, Retrofit will give you sane defaults for your platform but it allows for customization.
  • OkHttp : OkHttp perseveres when the network is troublesome: it will silently recover from common connection problems. If your service has multiple IP addresses OkHttp will attempt alternate addresses if the first connect fails.
  • Async Http Client : The Async Http Client library’s purpose is to allow Java applications to easily execute HTTP requests and asynchronously process the HTTP responses. The library also supports the WebSocket Protocol. The Async HTTP Client library is simple to use.

2. Image Loader  

  • Picasso : Images add much-needed context and visual flair to Android applications. Picasso allows for hassle-free image loading in your application—often in one line of code!
  • Fresco :Fresco is a powerful system for displaying images in Android applications. Fresco takes care of image loading and display, so you don’t have to. It will load images from the network, local storage, or local resources, and display a placeholder until the image has arrived. It has two levels of cache; one in memory and another in internal storage.

3. JSON

  • Gson : Gson is a Java library that can be used to convert Java Objects into their JSON representation. It can also be used to convert a JSON string to an equivalent Java object. Gson can work with arbitrary Java objects including pre-existing objects that you do not have source-code of.
  • Jackson : Jackson is a suite of data-processing tools for Java (and the JVM platform), including the flagship streaming JSON parser / generator library, matching data-binding library (POJOs to and from JSON) and additional data format modules to process data encoded in Avro, BSON,CBOR, CSV, Smile, Protobuf, XML or YAML; and even the large set of data format modules to support data types of widely used data types such as Joda, Guava and many, many more.

4. Layout

  • WaveView : A wave view of android,can be used as progress bar.
  • AndroidSwipeLayout : Android Swipe Layout Can be easily integrated in anywhere, ListView, GridView, ViewGroup etc. It Can notifiy the hidden children how much they have shown. It Can be nested each other.
  • ExpandableLayout : ExpandableLayout provides an easy way to create a view called header with an expandable view. Both view are external layout to allow a maximum of customization.
  • Dragger : The library was created in order to provide new animations for activities on Android. Using the ViewDragHelper class, it is possible to create smooth animations that allow full control of the view by the user.  Dragger now uses Rebound(tiny, 41.7kb) from Facebook to provide more realistic animations and improve performance for old devices.

5. List/Grid

  • Expandable ListView : Expandable ListView is a type of view very much similar to a  List view.This view shows items in a vertically scrolling two-level list.This has two levels – group and children, which differs it from the List view.Group individually be expanded to show its children.
  • FlabbyListView : Android library to display a ListView which cells are not rigid but flabby and react to ListView scroll and touch events.
  • ParallaxListView : Parallax is a displacement or difference in the apparent position of an object viewed along two different lines of sight, and is measured by the angle or semi-angle of inclination between those two lines.
  • StickyListHeaders : StickyListHeaders is an Android library that makes it easy to integrate section headers in your ListView. These section headers stick to the top like in the new People app of Android 4.0 Ice Cream Sandwich. This behavior is also found in lists with sections on iOS devices. This library can also be used without the sticky functionality if you just want section headers.
  • AndroidTreeView : Android Tree view is N – level expandable/collapsable tree. It uses Custom values, views, styles for nodes. It Save state after rotation.

6. View Pager

  • CircleIndicator : A lightweight viewpager indicator like in nexus 5 launcher. It gives the circles in the list that tells the exact location or number of the list.
  • Android ViewPagerIndicator : Paging indicator widgets that are compatible with the ViewPager from the Android Support Library to improve discoverability of content. These widgets can also be used in conjunction with ActionBarSherlock!
  • MaterialViewPager : Material Design ViewPager easy to use library. Use to get a beautiful screen and enable preview. You can use MaterialViewPager as an usual Android View.

7. Action Bar

  • FadingActionBar : FadingActionBar is a library which implements the cool fading action bar effect that can be seen in the new Play Music app. This library uses the techniques outlined by Cyril Mottier in a popular blog post. The three most commonly used action bar implementations are supported: stock (API 11+), ActionBarCompat and ActionBarSherlock.
  • GlassActionBar : GlassActionBar is an Android library which implements a glass-like effect for the action bar. The three most commonly used action bar implementations are supported: stock (API >13), ActionBarCompat and ActionBarSherlock.

8. Dialog

  • MaterialDialog : It’s very easy to use. Just new it & call show() method, then the beautiful AlertDialog will show automatically. It is artistic, conforms to Google Material Design.
  • BlurDialogFragment : This project allows to display DialogFragment with a burring effect behind. The blurring part is achieved through FastBlur algorithm.
  • DialogPlus :  DialogPlus provides 3 position:  Top : Dialog will appear at top with animation, Center : Dialog will appear in the center with animation, Bottom : Dialog will appear at the bottom of the screen with animation

9. Progress Bar

  • SmoothProgressBar : Small library allowing you to make a smooth indeterminate progress bar. You can either user your progress bars and set this drawable or use directly the SmoothProgressBarView.
  • NumberProgressBar : There are several attributes you can set: The reached area and unreached area: color, height and The text area: color, text size, visibility and distance between reached area and unreached area The bar: max progress, current progress.
  • CircleProgress : There are several attributes you can set: DonutProgress, CircleProgress, ArcProgress.
  • FABProgressCircle : Android library to provide a material progress circle around your FloatingActionButton. This component is compatible with any existent FAB. The animation will start playing everytime the user clicks on the button. Developers should control the potential spam click in their fab buttons, to not allow the users to click on it if the asynchronous task and the progress animation are already running / playing at that very moment.
  • Loading : Loading is a project with kinds of Android loading view.

10. Material

  • MaterialDesignLibrary : If you want use this library, you only have to download MaterialDesign project, import it into your workspace and add the project as a library in your android project settings.
  • DrawerArrowDrawable : A simple drawable backport of the new drawer-indicator/back-arrow rotating drawable from the upcoming Android L.
  • MaterialTabs : Custom Tabs with Material Design animations for pre-Lollipop devices. It gives the swipe gesture to your tabs.
  • PagerSlidingTabStrip : Interactive paging indicator widget, compatible with the ViewPager from the Android Support Library.

These are list of android libraries that every developer should use in their app to make the app attractive. All these android libraries are very helpful to make the android developer’s life easy.

Conclusion

Technology has afforded many individuals the opportunity of owning a mobile phone. These android libraries helps you to make the best UI for your app. These android libraries make your app attractive, smooth, reliable.
There are various native e-commerce mobile apps available in the market for example SocialAPIMagentoShop – Shopping AppWooShopee – Woocommerce AppClovia etc that use these android libraries and looking good.

iplogoSocialAPI
Looking for a native Social Engine app builder (iOS/Android) for your Social Community? Try the 30-day free trial of our SocialaPI mobile app, go mobile commerce in a few hours and increase your connection. No Setup Fee, Pay as you go pack at just $60/month.

magento-logo
MagentoShop
Looking for a native Magento mobile app builder (iOS/Android) for your Magento based online marketplace? Try the 30-day free trial of our Magento mobile app, go mobile commerce in a few hours and increase your sales exponentially. No Setup Fee, Pay as you go pack at just $69/month.

wooshopee_logoWooShopee – Woocommerce App
Looking for a native Woocomerce mobile app builder (iOS/Android) for your Woocommerce based online marketplace? Try the 30-day free trial of our Magento mobile app, go mobile commerce in a few hours and increase your sales exponentially. No Setup Fee, Pay as you go pack at just $69/month.

Portfolio Items