dotnet / MobileBlazorBindings

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

Struggling to add webview to control existing MBB app #292

Open lachlanwgordon opened 3 years ago

lachlanwgordon commented 3 years ago

I'm trying to add a BlazorWebView to the Control Gallery app so I can reproduce, and hopfully fix #286. Based on the HybridApp sample I think I've done everything right but I end up with a blank white area where my webview should be.

In the debug output in Visual Studio I get 2021-01-12 12:05:56.569325+1100 ControlGallery.iOS[42638:745934] [Process] 0x7fbeb7b67020 - [pageProxyID=6, webPageID=7, PID=42641] WebPageProxy::didFailProvisionalLoadForFrame: frameID = 3, domain = NSURLErrorDomain, code = -1002, which I think is relevant but I can't find any meaningful solutions.

Repro of this issue is at https://github.com/lachlanwgordon/MobileBlazorBindings/tree/issues286

Any ideas?

Steps I've taken:

I've also modified the ShellNavigationManager to fix an issue with having a route "/", to stop the app crashing. I'll create a separate issue for this.

Eilon commented 3 years ago

Hmm interesting, I'll have to take a closer look. Hybrid apps have quite a few additional requirements compared to non-hybrid apps so it's possible that there's some 1-line thing that's missing somewhere.