Skip to content

Ability to intercept URL #293

@SimplyJaymin

Description

@SimplyJaymin

Hello,
How can I intercept a URL before it is loaded into the webview & stop loading?
I tried the following -
_onStateChanged = flutterWebviewPlugin.onStateChanged.listen((WebViewStateChanged state) { if (state.url.startsWith("someScheme")) { flutterWebviewPlugin.stopLoading(); } });

But the onStateChanged is called after the url has loaded into the webview, so I cannot stop the loading.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions