How To Become A Uno Platform Developer

Since its inception, Uno Platform has become popular for building cross-platform applications, including mobile apps on Android and iOS, or even an enterprise solution that can run across the desktop, mobile, and the web. Besides, Uno Platform applications can also be run on other platforms including Web/ WebAssembly, Windows, Linux, and macOS.

As a free and open-source development platform, Uno Platform has been used to build hundreds of applications and has a growing community of developers. Designed for pixel-perfect applications, Uno Platform has been used to deliver a consistent application visual across all platforms. At the same time, it can integrate with the native UI framework on the target platform, thus providing a native look to its applications.

As an application developer, why should you choose Uno Platform for your next cross-platform development project? Let us discuss this and more in the following sections.

Why should you become a Uno Platform developer?

Here are 10 reasons why you should choose to become an Uno Platform developer,

  1. Free and open-source development platform that is available under the Apache 2.0 license.
  2. Leverage your C# and XAML coding skills to build applications for Web/WebAssembly, Android, and iOS.
  3. Reuse a single codebase on 6 different platforms namely Android, iOS, macOS, Windows, Linux, and WebAssembly.
  4. Supported by third-party packages and libraries – including the Microsoft Windows Community Toolkit, SyncFusion, Infragistics, SkiaSharp, and Prism.
  5. Leveraged by Microsoft’s investment into developer’s tooling languages like .NET and C#.
  6. Compatible with the Progressive Web Apps (PWA) software, built using web technologies like HTML, CSS, and JavaScript.
  7. Compatible to work on popular development environments or IDEs like Microsoft Visual Studio, JetBrains Rider, Visual Studio Code, and Visual Studio Mac.
  8. Designed to run on Xamarin runtime (and not Xamarin.Forms) environments that are now available on .NET 6.0.
  9. Build a range of web applications using Visual Studio tool, which can then be transformed using the Uno Web Bootstrapper into static websites.
  10. Cross-platform apps that are natively compatible with touch, keypad, mouse, pen, and more.

Next, let us look at some of the prerequisites for learning and building an Uno Platform project.

What are the prerequisites of the Uno Platform app?

Knowledge of the C# and XAML would be helpful (but not necessary) for learning and building an Uno Platform application.

To build an Uno Platform app, here are the system requirements (or prerequisites),

  • Visual Studio 2019 (version 16.3 or later) with:
    • .NET (Xamarin) for mobile app development with the following:
      • iOS remote simulator for iOS development
      • Visual Studio for Mac and XCode version 8.2 (or later)
      • Google Android x86 emulators for Android development
    • Visual Studio extensions (for VSIX projects)
    • ASP.NET along with .NET Core 2.2 (for web development)
    • .NET Core (for cross-platform development) with versions:
      • .NET Core 3.1 SDK (version 3.1.8 or later)
      • .NET Core 5.0 SDK (version 5.0 or later)
    • For Microsoft Universal Windows Platform (UWP) development, all the latest UWP SDKs (beginning from version 10.0.14393)
  • Android SDK manager tools with Android SDK version starting from 7.1.

What is XAML and how does its knowledge contribute to Uno Platform? Let us see next.

Introduction to XAML

Short for eXtensible Application Markup Language, XAML from Microsoft is a declarative language that makes it simple to define UI elements with data binding. Some of the Graphic UI systems that make use of XAML include Xamarin Forms, .NET Core, Microsoft UWP, and Uno Platform. Essentially, the Uno XAML component looks similar to the UWP XAML component.

With XAML language, you can now create visible UI elements through its markup language – and separate the UI code from its runtime logic. Unlike other markup languages, XAML allows direct instantiation of code objects in place of an interpreting tool. Thus, XAML allows a workflow where the developers can work separately on the UI elements and application logic using different tools.

XAML and Uno Platform

How does XAML contribute to Uno Platform development? XAML allows Uno Platform to create and run the same application code on its supported platforms. The Uno.UI library reproduces the UWP APIs including all its namespaces. As a result, on Windows, and Uno Platform application does not use Uno.UI library at all – but is compiled as any other single-platform UWP application.

On its part, the Uno.UI library renders the same and consistent UI on every platform – including its UI panels, control templates, and arrangements of UI elements. Here is how XAML is rendered on all other platforms like,

  • Web (or WebAssembly)
  • Apple iOS
  • Google Android
  • macOS
  • Linux (Skia)

During the application build, the Uno.UI takes the shared codebase – comprising of XAML markups, C# code, images, and other assets – and creates the native application for the target platform.

Let us now move on to how to get started on the Uno Platform.

How to get started with Uno Platform?

As mentioned earlier, Uno Platform enables you to write application code once using C# and XAML and then deploy the application on the target platform. 

Selecting your development environment

The first step to getting started on Uno Platform is to set up your development environment based on the chosen operating system,

  • Windows
  • macOS
  • Linux

If you are developing your application on Windows operating system, you can use any of the following IDE tools,

  • Visual Studio
  • VS Code
  • JetBrains

The following table depicts the supported target platform for each of these IDEs on Windows.

Target Platforms
IDEs Windows 10 Android iOS Web or WebAssembly macOS Linux Windows 7 (or higher)
Visual Studio Yes Yes Yes Yes No Yes Yes
VS Code No No No Yes No Yes Yes
JetBrains Yes Yes Yes Yes No Yes Yes

If you are developing your application on macOS operating system, you can use any of the three IDE tools (as for Windows).

The following table depicts the supported target platform for each of these IDEs on macOS.

Target Platforms
IDEs Windows 10 Android iOS Web or WebAssembly macOS Linux Windows 7 (or higher)
Visual Studio No Yes Yes No Yes Yes No
VS Code No No No Yes No Yes No
JetBrains No Yes Yes Yes Yes Yes No

If you are developing your application on a Linux operating system, you can use either the VS Code or the JetBrains Rider IDEs.

The following table depicts the supported target platform for these IDEs on Linux.

Target Platforms
IDEs Windows 10 Android iOS Web or WebAssembly macOS Linux Windows 7 (or higher)
VS Code No No No Yes No Yes No
JetBrains No Yes No Yes No Yes No

Next, let us look at how to create a new Uno project on Visual Studio and Visual Studio Code.

Getting started on MS Visual Studio

Before creating your first Uno project on Visual Studio, make sure that you satisfied all the prerequisites (as discussed in the "Prerequisites" section) as well as installed the Uno extension on this IDE tool.

To create a new project, here are the main steps you need to follow,

  1. Launch Visual Studio and then click File > New > Project.
  2. Following that, select the “Cross-Platform App (Uno Platform)” option to create a new Uno project with the default template.

If you want to install the “Uno Platform templates” extension, complete the following steps,

  1. Using Visual Studio, click Extensions > Manage Extensions.
  2. From the Extension Manager tool, search for “Uno Platform Templates.”
  3. Next, install the “Uno Platform Solution Templates” extension. Alternatively, you can download the extension from the “Visual Studio Marketplace” extension.

Getting started on MS Visual Studio Code

Here is how you can create your first WebAssembly app for Uno Platform using MS Visual Studio Code. As the prerequisite, make sure you have installed the following along with Mono for Windows and the .NET Core SDK package (with both version 3.1 and 5.0).

To create a new Uno project, here are the main steps you need to follow,

  1. From the VS Code terminal, install Uno Platform templates.
  2. Next, create the new Uno project with support for the WebAssembly platform.
  3. For debugging your new WebAssembly app, perform the following steps,
    1. On VS Code, install the C# and JavaScript Debugger extensions.
    2. Open the project in the VS Code terminal using the application name.
  4. Modify the default template (as required) using the MainPage.xaml file.
  5. Run and debug the application using the “.NET Core Launch (Uno Platform App” configuration.

Creating an app with Uno Platform

How do you create a multi-platform app using Uno Platform? Here are the main steps that can get you started,

  1. Create a new project using MS Visual Studio.
  2. Next, search and select “Cross-platform App (Uno Platform)” and then name your Uno project app in the next step.
  3. From the “Shared” project, open the MainPage.xml file and add your application code.

To run your project, select “UWP” as the startup project and “x86” as the platform, before clicking Run. Alternatively, you can select “WASM” as the startup project and run your app on your web browser.

Additional training options for Uno Platform

Uno Platform provides additional training to developers through its open-source Uno Platform Workshop that you can attend from the comfort of your home. For instance, the Uno Bootcamp is a daylong online workshop where you can learn the development philosophy of Uno Platform and build a new application right from scratch.

These Uno Platform workshops cover a range of topics including,

  • The Uno tooling and development ecosystem
  • How to create rich and interactive UI-based applications
  • Working with native platform code

Besides that, you can now be part of the growing Uno Platform community – and learn how to contribute your expertise to Uno Platform learning.

Additionally, you can improve your understanding of Uno Platform from its documentation page that includes,

  • How to get started with Uno Platform
  • Real-world examples along with code
  • Principles of Cross-platform development with Uno Platform
  • API reference guides

Conclusion

As an open-source cross-platform application development framework, Uno Platform offers many benefits such as code reuse, support on multiple platforms including Windows, Android, and iOS. As an app developer, you can boost your career by learning this growing development platform supported by Microsoft. 

Through this guide, we have covered topics like prerequisites, how to get started with Uno Platform using MS Visual Studio and VS Code, and how you can advance your knowledge through its online workshops and learning resources.

Do you think it is worth investing your time in learning Uno Platform? Do let us know your thoughts.


Similar Articles