I have 2 web apps:
- UI in React JS
- API using ASP.NET Core MVC
They work fine when hosted on IIS, but I need them working on a local computer as a part of the standalone desktop app that doesn't have access to the internet. React app will be pre-compiled as HTML and displayed in a WebView2 component. As about starting servers, I thought that I could call CreateHostBuilder
from WPF, but decided to ask for recommended approach in this case.
https://learn.microsoft.com/en-us/aspnet/core/fundamentals/host/hosted-services
The question
How to
- Start UI server
- Start API server
- Start WPF and point WebView / Browser control to UI server
Bonus point, if these servers will not be available from a regular web browser installed on this computer, only from WPF WebView.