goTo method

  1. @SupportedPlatforms.new(platforms: [AndroidPlatform(), IOSPlatform(), MacOSPlatform(), WebPlatform(), WindowsPlatform()])
Future<void> goTo({
  1. required WebHistoryItem historyItem,
})

Navigates to a WebHistoryItem from the back-forward WebHistory.list and sets it as the current item.

Officially Supported Platforms/Implementations:

  • Android WebView
  • iOS WKWebView
  • macOS WKWebView
  • Web <iframe> but requires same origin
  • Windows WebView2

Parameters - Officially Supported Platforms/Implementations:

  • historyItem: all platforms

Use the PlatformInAppWebViewController.isMethodSupported method to check if this method is supported at runtime.

Implementation

@SupportedPlatforms(
  platforms: [
    AndroidPlatform(),
    IOSPlatform(),
    MacOSPlatform(),
    WebPlatform(),
    WindowsPlatform(),
  ],
)
Future<void> goTo({required WebHistoryItem historyItem}) {
  throw UnimplementedError(
    '${PlatformInAppWebViewControllerMethod.goTo.name} is not implemented on the current platform',
  );
}