dotnet / MobileBlazorBindings

Experimental Mobile Blazor Bindings - Build native and hybrid mobile apps with Blazor
MIT License
1.2k stars 151 forks source link

Blazor Desktop plans and productization #338

Open Eilon opened 3 years ago

Eilon commented 3 years ago

Hello fans of Mobile Blazor Bindings!

As some of you may know, we are working on productizing some key components of Mobile Blazor Bindings and will release them later this year (2021) as part of .NET 6. Our main focus will be on desktop support for Windows and macOS, but we are looking to enable authoring apps on as many platforms as possible.

What does "productization" mean? That means that the features that ship in .NET 6 will be fully supported and not experimental. The features will abide by all the same benefits and policies of anything in .NET 6, such as compatibility, breaking changes, paid support, patch releases, etc.

The work for this will mostly be done in the ASP.NET Core GitHub repo because that's where the rest of Blazor is and much of the code is shared.

To get a glimpse of some of the features and issues we're looking at you can query issues using the feature-blazor-desktop label on the ASP.NET Core repo: https://github.com/dotnet/aspnetcore/labels/feature-blazor-desktop

If you have thoughts or comments on any of those issues, please add them to the issues!

Thanks, Eilon Lipton

boukenka commented 3 years ago

Hi @Eilon,

I watched your excellent demo here: Creating native and hybrid mobile apps with Mobile Blazor Bindings. I really enjoyed it. 😄 After reading your comment above, I have to say that I am a little confused. Maybe I didn't interpret your comment correctly. Is it still planned/included that Mobile Blazor Bindings will be fully supported (and no longer experimentally) on iOS and Android for .NET 6? Or is that for later?

Eilon commented 3 years ago

In .NET 6 we will build a BlazorWebView control for .NET MAUI and it will be supported on Windows and macOS. You will be able to host Blazor Web content (HTML/CSS/etc.) in a native desktop app.

The rest of Mobile Blazor Bindings, such as mobile platforms, and support for native controls (for example, Button, Label, etc.) will continue in this repo and we hope to productize it in future .NET releases.

dcuccia commented 3 years ago

@Eilon this is helpful, thank you, and it was great to see this work get some official mention at .NET Conf last week. Congrats on the project's success - can't wait to use it in production.

Excuse the enthusiastic questioning, but can you say anything about:

  1. if/when MBB on Nuget will get a 6.0-Preview1 compatible release?
  2. if/when MBB will release the WPF BlazorWebView?
  3. if/when MBB will release a Catalyst MacOS BlazorWebView?
  4. what might be coming in related news in v0.6?

Thanks! David

Kukks commented 3 years ago

Why is Linux not being considered?

Eilon commented 3 years ago

@Kukks for .NET MAUI support we would like to run wherever .NET MAUI runs. If there is some GTK (or other) solution for MAUI, it's something we will look at. It's just about prioritization right now: we know we can deliver to Windows and macOS and they represent a huge part of the target audience.

Eilon commented 3 years ago

@dcuccia said:

  1. if/when MBB on Nuget will get a 6.0-Preview1 compatible release?

I don't have a date; we're busy working on the official .NET 6 parts of the project right now.

  1. if/when MBB will release the WPF BlazorWebView?

There is one you can use right now in the nightly feed! I have a sample app for WPF and WinForms here: https://github.com/Eilon/MobileBlazorBindings-WindowsDesktop

  1. if/when MBB will release a Catalyst MacOS BlazorWebView?

Using Catalyst on macOS is the plan in .NET 6.

  1. what might be coming in related news in v0.6?

You can check out the closed items in the preview 6 milestone here: https://github.com/dotnet/MobileBlazorBindings/milestone/6?closed=1

There's actually quite a lot in there already, and all of it is on the nightly feed: https://docs.microsoft.com/mobile-blazor-bindings/contribute/nightly-builds

cedwards-telis commented 3 years ago

I think the project naming is confusing me.

"Mobile" blazor bindings in the .net 6 timeframe is only shipping in Desktop guise on Windows and macOS where it will be called Blazor Desktop hence your sample projects being in MobileBlazorBindings-WindowsDesktop. Gulp.

But sadly Mobile blazor bindings isn't shipping for iOS and Android in the .net 6 timeframe.

Or is it just the native controls version of Mobile blazor binding that isn't shipping, the HTML version on iOS and Android will be shipping in the .net 6 timeframe??

However at some point in the .net 6 timeframe the Mobile blazor binding native control version (still in experiment mode) will be upgraded to support .net 6.

Eilon commented 3 years ago

Hi @cedwards-telis I agree some of the naming is confusing! This experimental project in this repo started out as only iOS/Android, so that's why it was has "Mobile" in the name.

But here's the full plan that we have:

  1. In .NET 6 (released this year 2021) we will support building Windows and macOS apps that contain Blazor web UI (a "hybrid app"). These apps have native UI using technologies such as XAML and also web UI (HTML/CSS) in a new BlazorWebView control. It is most likely true that we will also enable building Android/iOS apps but we have not committed to it being a supported scenario.
  2. The Mobile Blazor Bindings (MBB) project will be updated to support .NET 6 and will "add on" any features that didn't make it directly into .NET 6. So, the BlazorWebView in MBB will get deleted because it will be built-in to .NET 6. But the native UI controls such as Entry, Grid, Label, etc. will continue to live here. They will change from using Xamarin.Forms (what it uses today) to instead use .NET MAUI.

I hope this clears a few things up!

dcuccia commented 3 years ago

@Eilon thanks for your detailed replies (sorry for the late reply on my end). So happy to see BlazorWebView in .NET 6.0 Preview 3!

https://devblogs.microsoft.com/aspnet/asp-net-core-updates-in-net-6-preview-3/

199621616 commented 3 years ago

@Eilon wants to keep a way to support win7. If. Net Maui does not support win7, blazorwebview built into. Net Maui does not support win7. If so, you want to keep blazorwebview in MBB to support win7.

Eilon commented 3 years ago

We will ship BlazorWebView that runs on WPF and WinForms on .NET 6. Those should work fine on Windows 7.

CalaxDev commented 3 years ago

What/Where exactly is the difference between this Repo and MAUI Blazor?

I've stumbled upon this Repo not too long ago and I'm somewhat confused at the moment

codemonkey85 commented 3 years ago

@Z3roCoder This repo (Mobile Blazor Bindings) lets you write your UI code using Xamarin / .NET MAUI controls with the Blazor model and syntax. Basically you're writing a Xamarin / MAUI app, just with a different model.

MAUI Blazor will let you host a Blazor app (so HTML and razor etc.) within a native app, specifically inside a webview wrapped in a native UI. The Blazor app itself does not use native controls, but rather web-based controls, although you can use native controls for the rest of the app outside of the webview. Those controls would be written using the normal Xamarin / MAUI model (XAML / C#).

Does that make sense?

lonix1 commented 3 years ago

@codemonkey85 So MAUI Blazor is like phonegap/cordova, whereas MBB (this repo) is properly native?

If this repo is still experimental, is MAUI Blazor also? Or will it be released next month in .net 6?

Eilon commented 3 years ago

Mobile Blazor Binding enables building both native UI (true native UI controls) and hybrid UI (using web/HTML/CSS) in native apps. This is experimental for now.

Blazor Desktop runs on .NET MAUI, WPF, and WinForms, and enables building hybrid apps. This will release next year (it got moved out of .NET 6: https://devblogs.microsoft.com/dotnet/update-on-dotnet-maui/). This will be 100% supported.

lonix1 commented 3 years ago

So MAUI is to be released in net7 (november 22), and this repo, maybe yes maybe no.

You realise it's a race between them and you? I'm betting on you, because this project is way more useful than what I've read on maui. :smile:

Best of luck @Eilon!

codemonkey85 commented 3 years ago

@lonix1 It's not a competition - MBB and Blazor Hybrid are solving similar needs but in different ways. There is room for both in my opinion.

Eilon commented 3 years ago

@lonix1 .NET MAUI will be after .NET 6 and before .NET 7.

And it can't possibly be between "them and me" because I'm both of them 😄

lonix1 commented 3 years ago

Eilon I've heard of wearing multiple hats, but that is just ridiculous - now I have to bet on both projects!! :smile:

But seriously, MBB is truly exciting stuff. V1 can't come soon enough!

bangclash commented 2 years ago

I hope this moves to product soon. I've watched demos and this seems very impressive. I know a lot of people love xaml but it just doesn't click with me. The blazor syntax just looks much better to me. Hope to hear more in 2022.

janseris commented 2 years ago

Is this project of "Blazor Native" still active or has been abandoned and its continuation is the BlazorWebView component? @Eilon Thanks

Eilon commented 2 years ago

This isn't dead, but it's a low priority now. We'd love to eventually productize something like this for some future version of .NET MAUI, but that is not a commitment, and we don't have specific plans.

AmirImam commented 2 years ago

This isn't dead, but it's a low priority now. We'd love to eventually productize something like this for some future version of .NET MAUI, but that is not a commitment, and we don't have specific plans.

I felt happy about the word "isn't dead", but what do you mean by "not a commitment"?

Eilon commented 2 years ago

Microsoft is not committed (yet) to ship a technology such as Mobile Blazor Bindings as an official product. It's something we're evaluating, but there is no commitment.

manishbisen commented 2 years ago

@Eilon Is there any plan for MBB in .net 7.Is there any roadmap of it ?

Eilon commented 2 years ago

We don't have any update at this time. We are all busy trying to ship .NET MAUI.

nowlights commented 2 years ago

MobileBlazorBindings will be released in .NET MAUI, but I have a question, .NET MAUI Blazor emulates a browser and hosts the application, but does MobileBlazorBindings run natively?

Eilon commented 2 years ago

.NET MAUI Blazor emulates a browser and hosts the application, but does MobileBlazorBindings run natively?

There is no browser emulation in any of these projects. The BlazorWebView control (in both Mobile Blazor Bindings, and in .NET MAUI), internally uses a platform-specific WebView control, which runs the JS code of Blazor, and also renders the HTML/CSS so that you can see the UI on the screen. All the C#/.NET code runs natively on the device/platform.

Outside of BlazorWebView, Mobile Blazor Bindings uses Razor syntax to render native controls onto the screen (as opposed to HTML/CSS-based controls).

In all of these cases, all of the C#/.NET code runs natively on the device, and has access to whatever features the device makes available to any other native app on the device. On iOS you can integrate with FaceID/TouchID. On Windows you can format the hard drive. On macOS you can read and write files to disk. On Android you can access SD cards. Etc.

janseris commented 2 years ago

Can't wait when Blazor mobile bindings are combined with MAUI. That's the best of all worlds. Because it will be Blazor syntax but no JS to render - this means grids (data grid etc.) with thousands of items interacting instantly just like in Windows desktop frameworks - that is not possible in JS.

Eilon commented 2 years ago

@janseris I believe that Blazor Web's list virtualization features should work fine in BlazorWebView as well, which can help immensely when there are more than a few hundred/thousand rows of data to display. More info here: https://docs.microsoft.com/aspnet/core/blazor/components/virtualization?view=aspnetcore-6.0

But, either way, I am starting to spend some time to incorporate @Dreamescaper 's amazing work on MAUI Blazor Bindings back into this repo. You can check out their project here, if you haven't seen it yet: https://github.com/Dreamescaper/BlazorBindings.Maui

codemonkey85 commented 2 years ago

@Eilon that makes me incredibly happy. I’m learning XAML, but I’m sure I can’t be the only one who prefers Blazor’s binding model, among other things.

janseris commented 2 years ago

@Eilon Is there any plan for MBB in .net 7.Is there any roadmap of it ?

You can't expect this being ever completed when there are like only 5 people programming both MAUI and this. They would need whole life to complete both platforms which it now almost takes for MAUI. Supposed to be shipped in ,NET 6 (November 2021) and is not working properly even 9 months later when officially relased in June 2022.

nowlights commented 2 years ago

dotnet Blazor MAUI, will have support for Apple Watch?

Eilon commented 2 years ago

@nowlights that question should probably go to the https://github.com/dotnet/maui repo, but I believe the answer is no, not for now. Please refer to an earlier discussion on this: https://github.com/dotnet/maui/discussions/1144 and you can add your thoughts there.

lonix1 commented 1 year ago

Hi @Eilon, since v7 was released in November, and MAUI is now a thing, is there any change in this project's status? Is it still purely "experimental", or is there interest in moving it forward?

Because to repeat what was said umpteen times above, this library is an absolute gamechanger.

AmirImam commented 1 year ago

Hi @Eilon, since v7 was released in November, and MAUI is now a thing, is there any change in this project's status? Is it still purely "experimental", or is there interest in moving it forward?

Because to repeat what was said umpteen times above, this library is an absolute gamechanger.

They working on BlazorBindings.MAUI Take a look at this repo https://github.com/Dreamescaper/BlazorBindings.Maui

lonix1 commented 1 year ago

Thanks, I know about that project, but I with the utmost respect to its author, I'm waiting for something official from Microsoft.

I hope Eilon can update us now that v7 is out.

Jemy191 commented 1 year ago

I hope that some form of this library become a real thing. I'm using MAUI blazor app and it a breeze to develop with. Real native "Blazor" would be awesome!

rf-0 commented 1 year ago

Thanks, I know about that project, but I with the utmost respect to its author, I'm waiting for something official from Microsoft.

I hope Eilon can update us now that v7 is out.

I've been waiting for an update on this as well for a while now. I'm surprised they aren't pushing this along with all the new blazor stuff. This would be indeed a game changer, especially for enterprise mobile development in MAUI. Xaml is something of the past and an unified syntax will be so much better.

Tagging @SteveSandersonMS

lmorar commented 10 months ago

What happened to this project? Microsoft abandoned it.