37

So, What happens to Xamarin.Forms?

What is Multi-platform App UI?

What is differences between MAUI and Xamarin

Where can we generate MAUI projects?

Anas Alweish
  • 2,818
  • 4
  • 30
  • 44
  • 2
    The blog post covers it all https://devblogs.microsoft.com/dotnet/introducing-net-multi-platform-app-ui/ We will begin shipping .NET MAUI previews later this year, and target general availability with .NET 6 in November of 2021. .NET MAUI will ship on the same 6 week cadence that Xamarin.Forms has been on. We have published the .NET MAUI roadmap on GitHub and invite you to join us there today! – SushiHangover Jul 04 '20 at 13:56

4 Answers4

38

With .NET 5 Microsoft begins the journey of unifying the .NET platform, bringing .NET Core and Mono/Xamarin together in one base class library (BCL) and toolchain (SDK), more about it here.

.NET MAUI is a name for a new upgraded solution as a Multi-platform App UI framework for building native cross-platform apps with .NET for Android, iOS, macOS, and Windows. It is the evolution of Xamarin.Forms, built on top of it, becoming and being a new flagship .NET solution for building native cross-platform apps.

For me personally it is great that .NET team will be more focused on development of this framework with already great Xamarin.Forms team which made a huge difference and improvement to the platform in the last year or two.

For now, the GitHub repository (July 2020), is pretty much the same as XF one, all the namespaces are System.Maui, but in future things will be very different. As they promised on keynote and other sources:

  • One project targeting multiple platforms and devices
  • One location to manage resources such as fonts and images
  • Multi-targeting to organize your platform-specific code

It will also provide you support for building the apps in different modern patterns and frameworks such as:

  • MVVM
  • MVU
  • RxUI

Tools to create and develop apps with .NET MAUI are:

  • Visual Studio
  • Visual Studio for Mac
  • Visual Studio Code

Since .NET Maui will be more involved in whole .NET development tooling, there will be support added for .NET Core CLI. In other words that means we will be able to create a new project from the command line with:

dotnet new maui

Main goals of .NET Maui are:

  • Improve app performance
  • Improve simplicity of control extensibility
  • Improve the simplicity of contributing
  • Enable developer options to use Model-View-Update (MVU) and Blazor

In last year or two Xamarin.Forms had a very frequent cycle of new releases and that will surely continue. The team will continue to work on it but also side by side .NET Maui will grow more mature and around the release with .NET 6, Xamarin.Forms will stop with features and new stuff.

After .NET Maui is fully available and ready Xamarin.Forms will continue to receive support for 12 months. More about the road map and development state of it can be found on the official GitHub page here and the whole wiki page is full of helpful info about future development.

Also here is a nice Q&A about .NET MAUI with David Ortinau on InfoQ here.

UPDATE: On September 15, 2021:

"The .NET team has been working hard with the community in the open on its development and we are committed to its release. Unfortunately, .NET MAUI will not be ready for production with .NET 6 GA in November. We want to provide the best experience, performance, and quality on day 1 to our users and to do that, we need to slip the schedule. We are now targeting early Q2 of 2022 for .NET MAUI GA." Source: https://devblogs.microsoft.com/dotnet/update-on-dotnet-maui/

Mark Whitaker
  • 8,465
  • 8
  • 44
  • 68
Almir Vuk
  • 2,983
  • 1
  • 18
  • 22
  • 2
    Everything from above was also explained in the video (in case if you prefer watching): https://youtu.be/qbHO8J3bId0 – Mar Oct 26 '20 at 07:43
11

UPDATE: This is the old answer which was correct at the time. MAUI is now launched. I think that the most notable difference is that MAUI is based on the latest .NET 6.

At this point Xamarin.Forms is a mature framework while MAUI is a blog post. That makes them hard to be objectively compared.

In general the idea for MAUI is to be a further evolution of Xamarin.Forms. Personally I don't see anything revolutionary (and even important) announced. The main difference will be that MAUI will be a single project with multiple outputs instead of multiple projects for each platform. There should be also some improvements in managing common assets as it was usual to place assets in platform projects and not in the common project, but most of that is possible in Xamarin even now so it is hard to say whether it is some kind of improvement or just a marketing trick.

Also support for macOS should go from beta to production. Again it is hard to say whether it will be some significant boost of fairly low quality in beta or just a marketing trick.

Ivan Ičin
  • 9,672
  • 5
  • 36
  • 57
  • 1
    MAUI might not be "revolutionary", but will be an updated version of Xamarin Forms. Initially there might not be any notable difference or new features other than single project supporting multiple platforms, but the main catch is that it will be based on latest .Net 6 and will be updated to support later versions of .Net like .Net 7 and later. If I am not mistaken, Xamarin Forms was based on legacy .Net Standard 2.0 version, and it was hard to maintain support and provide updates for them as well as developers. MAUI will see new features, better native support and stable releases further. – Junaid Pathan Aug 30 '22 at 01:58
7

Let's start with Architecture and History, which can resolve most of the differences.

Xamarin And MAUI History

  • Xamarin was introduced before the .Net Core, basically Microsoft acquired Xamarin as it enables to write code for Andriod and iOS using c#.
  • Xamarin is based on Mono Base Class Library (BCL). BCL libraries are those libraries that allows you to develop the applications.
  • Similarly, .Net Framework is based on Base Class Libraries, which are different then Mono BCL. So, we cannot share the code between different BCL and Mono BCL, that generates a limitations where we cannot write the code once and use it across multiple platforms.
  • Later .Net Core came which allows us to write a applications that can run on Windows, Android and iOS, but still it has it's own Core BCL.
  • Later, Microsoft comes up with the approach of .Net Standard, which allows to share the code across different BCL, like BCL for .Net Core, .Net Framework or Xamarin.
  • Now, Microsoft has decided to move to one .Net i.e. .Net 6, no more .Net Framework, .Net Core. It's all one platform for all types of applications.

What Xamarin can do

  • Xamarin is based on the Mono BCL. (Mono is the original open-source version of .Net).
  • Allow building Native Apps for Android or IOS. This gives capabilities to connect to the Native features of Android or IOS.
  • Note: Microsoft has decided to deprecate Xamarin support by November 2022.

Now Come to MAUI

  • .Net Multi Platform App UI

  • Similar to Xamarin, MAUI apps are written using XAML and C#.

  • Use the same code that can be used across the platforms.

  • In Xamarin, we create separate projects for Andriod or IOS, but in MAUI, you can use the single project structure combined with the shared project.

  • It is possible to write the Native specific code as well for Andriod or IOS in MAUI even though it has single project structure.

MAUI Architecture and Project Structure: (If Image not loading: use this: https://learn.microsoft.com/en-us/dotnet/maui/what-is-maui)

enter image description here enter image description here

Xamarin Architecture: (If Image not loading: use this: https://learn.microsoft.com/en-us/xamarin/get-started/what-is-xamarin)

enter image description here enter image description here

KushalSeth
  • 3,265
  • 1
  • 26
  • 29
  • So instead of Net standard, I can now use .net 6 as the backend of an asp.net core web application, and use that same backend code (DAL included) for a MAUI mobile application? Haven't used Xamarin or Maui yet just exploring options. – eaglei22 Sep 20 '22 at 15:03
  • 1
    I'm asking the same thing as @eaglei22 ;-) – Stronghold Nov 10 '22 at 21:15
5

MAUI is the next generation of Xamarin Forms with broader platform support. The first preview will be available in .NET 5 in Nov 2020, and the first production release will come with .NET 6 in Nov 2021.

BEFORE

Xamarin Forms will be supported for one year after MAUI is introduced in 2021, then will be deprecated in favor of MAUI.

Ivan Ičin
  • 9,672
  • 5
  • 36
  • 57
Jason
  • 86,222
  • 15
  • 131
  • 146