Does Cross-Platform Development Exist?

<p>Cross-platform apps sound like the future of mobile development. You can launch them on any device and the functionality will remain the same. But many developers are skeptical. Is it justified? Which approach is better?</p>

26 / 07 / 19

Cross-platform development creates apps that work the same across different platforms. You can launch them from any smartphone regardless of the OS. Sounds too good to be true, right?

That’s why many developers are very skeptical about it. It does indeed have its drawbacks. The capabilities of these applications are limited. Features and design are often sacrificed to maintain cross-platform implementation.

Is cross-platform development a viable practice or just a failed experiment? For that, we’ll look into three completely different approaches.




Xamarin 


Out of all approaches, this one resembles native development the most. The logic is done on object-oriented language C#, while the UI is written on XAML. It’s handy when you need to create an application quickly and the user interface is not a big concern. It has all the capabilities of .NET Core, but the advantages of this tool stop there. Xamarin used to have so much potential that Microsoft bought it. Despite that, the support didn’t improve. The drawbacks that were there at launch are still there to this day. And there are plenty of them:

  • Small community. If problems arise, it’s difficult to find a fix.
  • A small number of libraries. And even those are rarely updated.
  • No UI consistency. The same elements can look different not only on different platforms but even on different Android versions.
  • Incompatible with complex UI. Long rendering processes and lack of flexibility
  • Big application size.
  • Stability problems. Constant bugs and crashes.

Use Xamarin when:

  • You need a simple app with “client-server” infrastructure
  • Additional libraries aren’t needed
  • UI is not important
  • There are no resource-heavy processes

Avoid it when:

  • There are many styles and layouts 
  • UI has to be specific
  • UI has to remain the same

Book a free consultation and we’ll help you make the best choice for your business.




React Native and Expo


React Native is a truly native JavaScript framework. While others - Apache Cordova for example - just convert the app into WebView, this approach uses the OS of the device.

It has a sizeable community and various libraries that can be used to write UI elements among other things. It is structurally similar to React.js, which means that web-developers can work on it.

Expo makes it easier to use this service. It’s an SDK that comes pre-packaged with everything you may need during mobile development (things like notifications, NFC, and such). The platform doesn’t even have to be taken into account since everything is implemented on their servers.  

Expo has a separate debugging tool: Expo Client. It’s installed on smartphones and works without connecting to a computer. It’s also done with the help of their servers. Expo Client can also be used to look through demos of various libraries. You just scan the QR code, like demonstrated here

The only drawback is incompatibility with native components. As a result, libraries written in native languages can’t be used. But if this isn’t an issue, Expo helps develop a client application even quicker.



Progressive Web Apps


Progressive Web Apps (PWA) is a pretty new technology that is currently on the rise in popularity. Even though the development is not mobile per se, the result can be a mobile app. You can upload it to a store if need be, but it also works directly from the browser. In essence, it is a website that can work offline. It’s implemented with the help of Service Worker. It’s a JavaScript code that works in the background and does the cashing, while also handling the updates and notifications. 

You can check out all the capabilities of PWAs on whatwebcando.today. However, the feature list on iOS is not yet fully implemented, since Safari has fewer features than Chrome. Using Lighthouse during development is highly recommended. This extension analyzes a website and lets you know it is a PWA, pointing out any missing features if not.

If feature list and UI/UX of the mobile version of the website suits your needs, it can easily be converted into a PWA. In addition to an application that is ready to be uploaded to the market, you will get desktop versions for Mac, Windows, and Linux. If notifications aren’t important this is the smartest choice. 

4.8