handlesURLScheme method

  1. @SupportedPlatforms.new(platforms: [IOSPlatform(apiName: 'WKWebView.handlesURLScheme', apiUrl: 'https://developer.apple.com/documentation/webkit/wkwebview/2875370-handlesurlscheme', available: '11.0'), MacOSPlatform(apiName: 'WKWebView.handlesURLScheme', apiUrl: 'https://developer.apple.com/documentation/webkit/wkwebview/2875370-handlesurlscheme', available: '10.13'), LinuxPlatform(note: 'Returns true for built-in schemes (http, https, file, ftp, data, blob, about, javascript).')])
Future<bool> handlesURLScheme(
  1. String urlScheme
)

Returns a Boolean value that indicates whether WebKit natively supports resources with the specified URL scheme.

urlScheme represents the URL scheme associated with the resource.

Officially Supported Platforms/Implementations:

Parameters - Officially Supported Platforms/Implementations:

  • urlScheme: all platforms

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

Implementation

@SupportedPlatforms(
  platforms: [
    IOSPlatform(
      apiName: 'WKWebView.handlesURLScheme',
      apiUrl:
          'https://developer.apple.com/documentation/webkit/wkwebview/2875370-handlesurlscheme',
      available: '11.0',
    ),
    MacOSPlatform(
      apiName: 'WKWebView.handlesURLScheme',
      apiUrl:
          'https://developer.apple.com/documentation/webkit/wkwebview/2875370-handlesurlscheme',
      available: '10.13',
    ),
    LinuxPlatform(
      note:
          'Returns true for built-in schemes (http, https, file, ftp, data, blob, about, javascript).',
    ),
  ],
)
Future<bool> handlesURLScheme(String urlScheme) {
  throw UnimplementedError(
    '${PlatformInAppWebViewControllerMethod.handlesURLScheme.name} is not implemented on the current platform',
  );
}