Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

React Native vs Swift/Objective-C/Java Native

I'm working on a new project for a Fintech company and I have been tasked with looking into whether we should go with React Native or native Swift/Objective-C/Java for our mobile app development technology and strategy going forward.

I have done loads of research into this and have read many of the case studies relating to React Native, but I still don't feel I have enough to make an informed decision at this point.

The broad app functionality will include things like:

  • Data related functions such as Account Balances and Statements (pretty simple)
  • Image capture of identity documents and selfies of the users
  • Capture of biometric data
  • Push notifications

Some of this is pretty standard and simple, but some of it will require the app to use low level device functions and/or use 3rd party Android and iOS SDKs.

So, in terms of working towards the decision of a mobile development strategy, can I ask you for your input, based on your recent experience, on reasons to consider React Native over native Swift/Objective-C/Java development in the light of the planned functionality listed above (including reasons why it may be far better to stick with the native languages/platforms).

like image 843
Ozzy Avatar asked Feb 01 '17 09:02

Ozzy


People also ask

Does React Native use Objective-C or Swift?

Mostly React Native code is written with Objective-C because React Native core uses Yoga lib for layout that works better bridging with Objective-C because is written in C++. But how we can see on documentation we also can bridge our application with Swift to use these functionalities.

Is React Native better than Swift?

React Native vs Swift performance is another point to consider. Compared to a framework, a Swift app will perform better in most cases. Although it can consume more CPU power when running an application, Swift provides better performance than React Native.

Is React Native faster than Swift?

React Native is powered with JavaScript. Thus, up to 90% of the code for your mobile app may be taken from web applications. Building iOS apps with React Native is 33% faster than Swift and takes 1,5 months.

Do you need Swift for React Native?

No. It uses Libraries and internal APIs. The main difference between React Native and Swift is that RN can create cross-platform apps while Swift makes apps for Apple platforms only. In essence, Swift apps run on Apple devices while React Native apps can run on both iOS and Android.


2 Answers

From own experience I can tell that React Native is a good choice for most of the apps when you need to develop and iterate fast. It usually means it would be cheaper to develop for a customer.

Looking at the list of features I can not see anything that can not be done in RN. Sooner or later you'll have to dive into native code, usually to bridge native modules with JS. I've done this multiple times, it's not that hard and documentation on RN website helps a lot.

Be aware that you'll most certainly run into stupid bugs and you'll have to find workaround. At least this happened to me multiple times when I was building RN app half a year ago, maybe now it's more stable.

Also I believe it really depends on what are the devices of potential app users. I've never developed for Android, but heard from fellow developers, that on mid-level Android devices RN runs much slower, this should be tested from the very beginning.

like image 162
Roman Liutikov Avatar answered Oct 12 '22 17:10

Roman Liutikov


React Native has a really nice and tempting idea behind sounds like "unified and almost fully shareable codebase for different platforms including Web". But from my experience (not so extensive but still) the reality is a little bit different – at some point you will face some issues with native code for sure, and it would be really good if you have experienced Swift/Objective-C/Java developers in your team to deal with it. Don't trust the promises "all you need is just a React Front-End Developer". The React Native platform itself seemed to me more like a magical blackbox which I ran with a single command having no any idea what's inside and how it actually works. You have to know at least something about Xcode and Android Emulator even if Facebook is trying to hide this aspect it from you as much as they can.

TL;DR In my opinion if you really want to try React Native for something more complex than TodoMVC then you need to have at least 3 developers: Web (JavaScript/React), iOS (Swift/Objective-C) and Android (Java). Or just one Superhero.

like image 26
deepsweet Avatar answered Oct 12 '22 17:10

deepsweet