Web View

Inherits from Xamarin.Forms.ContentView

Embeds a web page into your Rock page. This control wraps the standard Xamarin Web View and should be used instead of the Xamarin one. It adds an initial loading indicator that will be visible until the web page actually loads. Otherwise your user might be looking at a blank area for a few seconds before anything shows up.

To ensure that the web page displays with the proper scale within the application be sure to add the following meta tag to the <head> of the page.

<meta name="viewport" content="width=device-width, initial-scale=1">

Note that the WebView control must not be embedded within a ScrollView; otherwise the content will be clipped. You do not need to define the HeightRequest and WidthRequest properties when using the Rock version.

If the embedded web page contains an iframe and only a blank page is shown, it may be a CORS issue. On iOS, these errors are "swallowed" meaning nothing will be shown. Keep in mind the domain of your API URL that the shell connects to your server with.

Properties

Property

Type

Description

Source

string

The initial URL to be used when the web view first loads.

Example

<Rock:WebView Source="https://rock.rocksolidchurchdemo.com/page/482" />

Last updated

⚙️ Powered by Rock RMS