MicrosoftEdge / MicrosoftEdge/WebView2Feedback

The control is not loading while using Webview2 in the HybridWebview custom renderer on the Xamarin.Forms.UWP platform.

Open
#3,673 4 comments 0 reactions 1 assignee View on GitHub

@maurawinstanley is already working on this.

Since Aug 1, 2023.

bug
Dominant language
PowerShell
Stars
526
Forks
67
PR merge metrics
No merged PRs in 30d

Description

Title: The control is not loading while using Webview2 in the HybridWebview custom renderer on the Xamarin.Forms.UWP platform.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/HybridWebview21359003660

We suspect that the source property is not set properly. Please find the code snippet for it below.

private const string LocalScheme = "ms-appx-web:///Content//";
public void LoadUrl(string url)
{
var uri = new Uri(url, UriKind.RelativeOrAbsolute);
if (!uri.IsAbsoluteUri)
uri = new Uri(LocalScheme + url, UriKind.RelativeOrAbsolute);

Control.Source = uri;

}

Note: The control rendered properly if we use WebView instead of WebView2.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.