WebView
Loads a
Urlor rawHtml, reports navigation throughNavigatedandNavigationFailed, and runs JavaScript throughEvaluateAsync.Give it a bounded slot (a fill row, an explicit height), since web content has no intrinsic size to measure against.
Properties
AllowsBackGestures
Whether swiping from the screen edge navigates back and forward through history.
Type: bool
Html
Raw HTML to load, overriding Url when set.
Navigated
Called with the final address each time a page finishes loading.
NavigationFailed
Called with the failure description when a load fails.
Url
The web address to load. Takes effect when Html is not set.
Methods
EvaluateAsync
Runs JavaScript in the current page and returns its result as a string.
| Parameter | Summary |
|---|---|
string javaScript | The script to evaluate. |
Returns
GoBack
Navigates back to the previous page in history, if any.
GoForward
Navigates forward to the next page in history, if any.
MeasureOverride
Content measurement. Panels recurse; controls delegate to the native SizeThatFits.
| Parameter | Summary |
|---|---|
Size availableSize | The size available for the view's content. |
Returns
Size: The desired content size.
Reload
Reloads the current page.