The Latest in .NET Development at VS Live Part 2

In the previous part, Mikael Gidmark, started sharing our experience from VS Live in Austin in May. There were three different workshops to choose from on the first conference day at VS Live. We decided to check out “Building Modern Mobile Apps”. The goal of the workshop was to provide an overview of a few different ways to develop modern apps.

VS Live

In this article I will share some things from the first part of the workshop with the topics of what to have in mind when selecting target platform and technology for development. Kevin Ford and Brent Edwards at Magenic were responsible for the workshop.

What Defines a Modern app?

  • Should work at the users units despite platform.
  • Should be able to store data in the cloud in a secure way.
  • Should minimize data traffic over the mobile network.

Which Target Platforms to Select

The three largest platforms on the market for mobile units is not surprisingly iOS, Android, and Windows. Since Windows is still a small player in the context, the workshop was focused on Android and iOS.

If you don’t have enough resources to develop an app for all platforms, or want to select a platform to start with, there is some things to consider.

If you look at sold units globally, Android has 81.6 %, and iOS 15.9 % (figures from Business Insider based on sold units in the world 2015). Given this it should be self-evident that you should select Android as the first platform, but it isn’t that simple

The spreading rate can differ in different target groups, and different regions. If you for example look at https://www.netmarketshare.com, you can see that sold units in Sweden is different with 58 % Android, and 38 % iOS (period 201507-201605). In the US it is basically the same with 58 % Android, and 34 % iOS.

Before you get started with the app development, it is therefore important to evaluate which platform that is most common in the region and target group that you aim at.

Challenges – Android

Some of the largest challenges of app development for Android are:

  • The large fragmentation of units regarding manufacturers, models, screen size, and OS version.
  • To be visible among all apps available in the Play store.

If you look closer to for example OS version, you can see that it drags before the OS version is updated. Today, almost every third Android unit uses KitKat, which was released in October 2013, and 23 % runs even older versions. This is probably partly that the mobile manufacturers aren’t that interested in releasing new OS versions to old units.

Challenges – iOS 

Some of the challenges of app development for iOS are:

  • Multiple screen sizes (although less than Android).
  • To be visible among all apps available in App store.
  • Apple sends by short notice updates that could result in apps not working properly.
  • You need a Mac (for iOS development).

iOS doesn’t suffer the same delay in OS, where 84 % of the units running iOS 9.

Development

If you decide to develop an app for multiple platforms, there are a number of technologies to choose from to help you share code between them. In the workshop, strengths and weaknesses of the following technologies were discussed:

  • Mobile adapted site
  • Specific platform (native)
  • Cordova
  • Xamarin
  • Xamarin.Forms

Mobile Adapted Site

Traditional site adapted for mobiles and tablets.

Pros:

  • There is a lot of experience in web development.
  • The same code base despite platform.
  • Fast development.

Cons:

  • Doesn’t display as the users expect on a specific platform.
  • Hard time working with the platform’s harware, for example GPS.
  • More difficult working offline.
  • Performance on the client side can be bad for CPU intense tasks.

Specific Platform (Native)

This means that you develop your app mainly for Android, iOS, or Windows.

Pros:

  • Displays as the users expect on the platform.
  • Best possible performance.

Cons:

  • No reuse of code. The app needs to be completely rewritten for new platforms.
  • Demands knowledge of all target platforms.

All Platforms – Cordova

Cordova is a hybrid solution where you basically develop in a web environment, providing a possibility to package an app for distribution in the different app stores. Cordova also offers plugins to integrate with the units’ hardware.

Pros:

  • Works in all platforms.
  • A great deal of the code can be reused.
  • The developer can reuse its knowledge in web development.
  • Fast development.

Cons:

  • The user can often see that it isn’t a pure iOS or Android app.
  • It can take a while before there are plugins for new functions in the hardware.
  • If a plugin is missing, you might need to write it yourself which requires a developer with knowledge about all target platforms.

All Platforms – Xamarin

Xamarin is a product which lets you write your apps in C#, and lets you divide code between different platforms. Xamarin has previously required a pretty expensive license, but since Microsoft bought them earlier, the product is now free and included.

Xamarin says that you can dive 80-90 % of the code, but the lecturer in this workshop think 60 % is closer to the truth.

Pros:

  • The app displays as the usrs expect in a specific platform.
  • A lot of code can be divided between the platforms.

Cons:

  • UI code and certain API code cannot be reused.
  • Requires a Mac to build and edit UI (when you develop for iOS).
  • As a developer, you need to know respective platforms’ API and UI framework.

All Platforms – Xamarin.Forms

Xamarin.Forms is an addon to Xamarin that abstracts the platform specific UI management, allowing the developrs to create user interfaces that can be shared between Android, iOS, and Windiws Phone.

Pros:

  • Same as Xamarin.
  • UI-´code that is reusable.
  • Some parts of the platforms’ APIs are abstracted.

Cons:

  • Requires both a Windows and a Mac machine to be able to build.
  • Some compromises regarding UI.

Summery

It is not self-evident which platform to select for your app, and you might need to check out the market to find out which the most common platform is for your target group.

When it comes to decide technology, all have both pros and cons. If you target users that aren’t that picky if the iOS app doesn’t follow Apple’s design guidelines in all aspects, you might finish faster with a Cordova app or a mobile site.

If you do have pickier users, Xamarin might be the right way without limitations in user interface and functions.

Peter Andersson Business Developer e-commerce, Team Manager