Cross-platform development: getting it right for your software project
The potential to save time and development costs by reusing the same code for multiple desktop and mobile platforms makes cross-platform a good choice for many applications.
When you’re making a significant investment in software development, however, you also want to be sure to avoid common pitfalls. Without the right choices in the project’s early stages you can create more problems than you solve and easily lose those cost and efficiency savings.
Advantages of cross-platform development
Cross-platform development uses a single codebase for each different platform the app will run on (for example, Android, iOS, Windows and macOS). The software is written using a universal language like .NET and development of the source code is supported by a development environment.
The benefits of cross-platform development include:
- one code base for the app, instead of different code for each operating system
- reach audiences across the different platforms
- reduced development costs (compared to developing separate apps)
- reduced time to market (compared to developing separate apps)
- simpler ongoing maintenance and development.
For example, Novarum DX use cross-platform development to save time on building medical apps. The Novarum Reader app uses a smartphone’s QR code scanner to simplify the interpretation of lateral flow test results. Back in 2019 Novarum DX built and shipped 20 different apps using cross-platform development, taking four to six weeks to build each and they aim for 80% code reuse between platforms.
How to do cross-platform development well
When cross-platform is the right choice for your project and your budget, it’s not a silver bullet. You need to make sure you get the right team around the table, because your software development partner’s depth of experience will make a big difference to how successfully your project achieves it goals.
1. Avoid too much development on only one platform
A common mistake is to assume it will work to code all or most of the app for one platform and then copy it across using your development framework. In reality, you need to work on each feature for all platforms as you go, so that you can identify any weaknesses in your cross-platform architecture. This is especially important when you’re working on the UI or on how apps access hardware features, as these will not be the same for different platforms.
When you pick up these discrepancies as you go along, it’s much easier to fix any problems. If you wait until the coding is largely or mostly complete, it’s going to be more difficult and more time consuming to fix.
2. Avoid too much development on separate platforms
Aa certain amount of platform specific coding will always be required, for example to access platform specific features such as a phone camera and also to create the UI for each OS. As a rule you should be aiming to have 80-85% of the code shared on all platforms. This represents a significant cost and efficiency saving.
We’ve also seen projects where an iOS developer will create a screen for the iOS app completely independently from the Android developer, who is working on the same functionality.
You may need separate skills to solve some different requirements for iOS and Android, but that doesn’t mean the team shouldn’t tackle the project in a co-ordinated way. By working on the same problem on all platforms at the same time, you open opportunities to share code and to maintain consistency in approach.
3. Use a development environment that does what you need
For your cross-platform development project to work smoothly, you need to select the right development environment. This is a piece of software that developers use to build different types of applications, allowing the team to keep all files and code in one place. One of the development environments we use at BioMedical is .NET, which is an open source developer platform created by Microsoft.
Your chosen development environment must support the platforms you want to build for (for example, Android, iOS, macOS and Windows) and the hardware features your software needs access to (for example, does the app need to use the smartphone camera?) Get this wrong and you could be half way through the project only to find your iPhone users will be locked out of specific app features. If fixing it requires starting with a new development environment, this could be an expensive mistake to put right.
4. Work to industry standards wherever possible
One of the challenges for cross-platform development is that the platforms you’re building for are regularly updated. Both the expertise of your development team and the development environment they’ve chosen are crucial for keeping up to date with those changes. You don’t want to fall behind.
As an example, data security is essential and security requirements evolve rapidly. By choosing a development platform aligned with industry standard coding, your app will be up to date with the latest security requirements including authentication protocols, role-based security, data encryption and data retention policies.
Find a development partner with cross-platform experience
It’s relatively easy to talk about how great cross-platform development is and what can be done with it, without having the evidence to substantiate those claims. A lack of experience can lead to delays and unforeseen costs.
You have ambitious plans for your products and your business: always look for a development partner who can provide evidence of their experience in cross-platform development projects and experience in your sector.