❔ How to have a Web Frontend and a C# backend (Desktop APP)?
I am wondering if there is a framework for this. I want to publish a .NET desktop application, however I am not too familiar with WPF and would rather stick to HTML/CSS/JS for the Frontend since I am a Web Developer. Is there a way to achieve this. Thanks in advance.
21 Replies
Hybrid apps are what you want
A desktop frontend gui with min. 1 WebView element that displays the content of a web backend
Can be done with WinForms, WPF, MAUI, and stuff
Blazor Hybrid I think it was called
That's just a loose name, pointing out the hybrid factor and using maui
Usually you see "MAUI" and "Blazor" combined when talking about that specific project type
So
Maui Blazor is a good option ?
Never used it myself, but it is the option if you want to have a web frontend
There isn't really anything else, sans wiring something up yourself
publishing it as desktop app isn't a problem, right? But I assume its windows only. It looks promising nontheless
I absolutely hate MAUI for its entire existence
damn
xD
But yeah, for the future it's probably the most viable option
I wish Avalonia had a webview
It's the future only if you consider 1st party frameworks
Avalonia sends its regards
Oh, there's no webview in Avalonia?
Odd
Nope
https://github.com/OutSystems/WebView
<:DFrido_Think:964211837749051483>
One sec
Ah yeah, the non-web hosting, but just web-rendering of blazor
https://github.com/AvaloniaUI/Avalonia/discussions/8414#discussioncomment-3052012
Yes, it's possible to implement.
Saying that, it's should be an interesting project, but it can't fit in the scope of our current release.
Another thing is that its relatively new and not much can be found about it yet
(speaking of Maui blazor)
not too popular yet sadly
Yee
If I wanted an x-plat desktop app I'd definitely use Avalonia
MAUI doesn't export for Linux
Everything else is Windows-only
^
wasnt linux support planned?
It was planned, as in "the community will support it lmao"
So there probably is some random repo by some random guy somewhere that adds some initial support for Linux
I remember Patrick sending me a random nuget that supposedly adds linux support
Lol
Cuz I made the statement that maui doesnt have loonix support
Since you said that Blazor Hybrid thingie can be used for Winforms, WPF and MAUI. which one should I use? Should I go for WPF if its planned to have only a desktop app
https://learn.microsoft.com/en-us/aspnet/core/blazor/hybrid/tutorials/?view=aspnetcore-7.0 see which tutorial is most developed, I guess?
I'd probably go with either WPF (since it can somewhat-easily be upgraded to Avalonia in the future) or MAUI (since it's at least somewhat x-plat)
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.